I wrote this code to show the primes between 1 and 100. The only condition is to do not use functions, whole code should be inline. I would ask if I can improve (optimize) it mu
If you just want primes below 100, there's no need to write code to compute them. It's perhaps a stupid answer, but it solves your problem as stated efficiently and concisely.
int main() {
cout << "Prime numbers are:" << endl << "2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97" << endl;
return 0;
}