1.7 Code Practice: Question 1
Write a program that uses two input statements to get two words as input. Then, print the words on one line separated by a space.
please help :(( i dont know this
Answers
Answered by
0
Answer:
This isn't a relatively tougher question as it seems. You Don't need to consider some kind of command line arguments or such.
Follow my code I'm explaining it lucidly.
Explanation:
I'm assuming all header files and Preprocessor directives or the required packages are imported,
Now the algorithm.
Start
Read a
Read b
Print a, " " ,b
The space will be printed as a character.
I'm using C++ to demonstrate
using namespace std
#include<iostream>
void main()
{
int a, b;
cout<<"enter 1st value \n";
cin>>a;
cout<<." Enter 2nd value \n";
cin>>b;
cout<<a<<" "<<b;
}
Similar questions