You have a 99 cell array. In each cell you put an integer belonging to the set {1,2,...,100}. No two cells contain the same integer. Thus when the array filling is complete, one of the integers from 1 to 100 is not present in the array. Determine which integer is missing from the array.

wu-forum thread

Write a program that will print "C" if compiled as an (ANSI) C program, and "C++" if compiled as a C++ program.

wu-forum thread

How well do you know C? "for" loops? Find three ways to make the program below to print 20 copies of the dash character '-' by changing/adding one character:

int i, n=20; 
for (i=0; i < n; i--) {printf("-");}; 
Wrong solutions:
  • Changing "n=20" into "n=-20" won't work.
  • Changing "i--" into "i++" doesn't satisfy the one character condition.
  • Changing "i=0" into "i=40" won't work.
  • Changing "i < n" into "i < -n" wont' work

wu-forum thread