diff options
| author | Connor McDowell <[email protected]> | 2024-03-09 18:48:11 -0800 |
|---|---|---|
| committer | Connor McDowell <[email protected]> | 2024-03-09 18:48:11 -0800 |
| commit | a1158c12daaae4972ec45f192011b9f2b8a89506 (patch) | |
| tree | a0e3298862aea6aed516c74bf4d12d91d3eaa9be /Project1/project.cpp | |
| parent | add deadline (diff) | |
| download | in-class-exercise-3-connormcdowell275-main.tar.xz in-class-exercise-3-connormcdowell275-main.zip | |
Diffstat (limited to 'Project1/project.cpp')
| -rw-r--r-- | Project1/project.cpp | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/Project1/project.cpp b/Project1/project.cpp new file mode 100644 index 0000000..f9451df --- /dev/null +++ b/Project1/project.cpp @@ -0,0 +1,31 @@ +// name: Connor Mcdowell +// date: 3/9/2024 +// class: CST 116 +// reason: in class exercise number 3. + +#include <iostream> + +using std::cin; +using std::cout; +using std::endl; + +int main() +{ + int input = 0; + cout << "Please enter a number: "; + cin >> input; + cout << " " << endl; + if(input == 0) + { + cout << "Your input is exactly 0!" << endl; + } + if(input < 0) + { + cout << "Your number is a negative number!" << endl; + } + if(input > 0) + { + cout << "Your number is a positive number!" << endl; + } + return 0; +}
\ No newline at end of file |