Answered step by step
Verified Expert Solution
Question
1 Approved Answer
What is wrong with my answer? It needs to be in C++ format and I'm using the website vocareum to do this. Here is the
What is wrong with my answer? It needs to be in C++ format and I'm using the website vocareum to do this.
Here is the question:
Ask the user for an integer. If the number entered is greater than 50, then respond in a certain way, otherwise respond in another way. For example:
Please enter an integer: 100 You entered 100, which is greater than 50.
and here is my answer:
#include int main(){ //Declare a variable to take input int num; //Prompt the user for input; cout<" Enter a number: "; cin>num; return 0; }
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started