Worldline interview question

Basic of c++ Projects Two programs like pattern