+ 1
The given program outputs "C++". Change the code to output each character on a new line, resulting in: C + +
2 ответов
0
#include <iostream>
#include <cstring>
const char* cpp = "C++";
for (int i = 0; i < std::strlen(cpp); i++)
std::cout << cpp[i] << "\n";
This should iterate to each character in the defined string literal
0