From afd857201e4f76636b81acb03fdebd7b34dccd5b Mon Sep 17 00:00:00 2001 From: austinlujan Date: Thu, 7 Mar 2024 14:07:54 -0800 Subject: number program done --- Project1/program.cpp | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) (limited to 'Project1/program.cpp') diff --git a/Project1/program.cpp b/Project1/program.cpp index e43207f..3af16c7 100644 --- a/Project1/program.cpp +++ b/Project1/program.cpp @@ -1,12 +1,34 @@ -// Name: Austin Lujan + // Name: Austin Lujan // Date: 1/16 // Class: CST 116 // Lecture +#include +using std::cout; +using std::cin; +using std::endl; int main() { + cout << "Enter a whole number: "; + + int number = 0; + + cin >> number; + + if (number > 0) + { + cout << "Your number is positive\n"; + } + else if (number < 0) + { + cout << "Your number is negative\n"; + } + else + { + cout << "Your number is zero\n"; + } return 0; } \ No newline at end of file -- cgit v1.2.3