Hello. I am writing a program in C++ using loops, conditionals, and file processing concepts. I wonder if you could show a pseudocode example representing such a program. This will help me visualize the basic structure of what the completed program will look like. Thank you in advance.
Best Regards,
Charlie
1
Expert's answer
2013-04-10T10:54:29-0400
program start; int i;& #define a int variable file f; #define a file variable f = fopen('example.txt','w'); #open file for writing for(i = 0;i<30;i++)& #& loop [0;30] { if(i mod 3 == 0) # condition: every number the divides into three parts without remainder { fwrite(f,i); #writing result to file fwrite(f,' ');& #separated by space } } fclose(f); #closing file program end.
Comments
Leave a comment