Answers for "rewrite small numbers from input to output. Stop processing input after reading in the number 42. All numbers at input are integers of one or two digits."

C++
0

life the universe and everything solution c++

#include <iostream>

int main()
{
    int input ;
    while( std::cin >> input && input != 42 ) std::cout << 't' << input << 'n' ;
    while( std::cin >> input ) ;
}
Posted by: Guest on October-23-2020

Code answers related to "rewrite small numbers from input to output. Stop processing input after reading in the number 42. All numbers at input are integers of one or two digits."

Browse Popular Code Answers by Language