aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CST116-Ch6-Debugging/CST116-Ch6-Debugging.cpp2
-rw-r--r--cst116-Ch6-Pearse-Pseudocode.txt11
-rw-r--r--cst116-Ch6-Pearse.txt6
3 files changed, 18 insertions, 1 deletions
diff --git a/CST116-Ch6-Debugging/CST116-Ch6-Debugging.cpp b/CST116-Ch6-Debugging/CST116-Ch6-Debugging.cpp
index 497e2f8..268a22e 100644
--- a/CST116-Ch6-Debugging/CST116-Ch6-Debugging.cpp
+++ b/CST116-Ch6-Debugging/CST116-Ch6-Debugging.cpp
@@ -51,7 +51,7 @@ int main()
// Breakpoint 1
// Put a breakpoint on the following line
- celcius = 5 / 9 * fahrenheit - 32;
+ celcius = 5.0 / 9.0 *(fahrenheit - 32);
cout << fahrenheit << " degrees F = "
<< celcius << " degrees C" << endl;
diff --git a/cst116-Ch6-Pearse-Pseudocode.txt b/cst116-Ch6-Pearse-Pseudocode.txt
new file mode 100644
index 0000000..e29dee7
--- /dev/null
+++ b/cst116-Ch6-Pearse-Pseudocode.txt
@@ -0,0 +1,11 @@
+main(){
+ float Celcius
+ float fahrenheit
+
+ print("Enter temperaure in Fahrenheit")
+ input(fahrenheit)
+
+ celcius = 5.0 / 9.0 * (fahrenheit - 32)
+
+ print(fahrenheit + "degrees F = " + celcius + "degrees C")
+} \ No newline at end of file
diff --git a/cst116-Ch6-Pearse.txt b/cst116-Ch6-Pearse.txt
new file mode 100644
index 0000000..e3960d6
--- /dev/null
+++ b/cst116-Ch6-Pearse.txt
@@ -0,0 +1,6 @@
+Enter temperature in Fahrenheit: 212
+212 degrees F = 100 degrees C
+
+C:\Users\legok\Source\Repos\cst116-ch6-debugging-legokid1503\CST116-Ch6-Debugging\x64\Debug\CST116-Ch6-Debugging.exe (process 21468) exited with code 0.
+To automatically close the console when debugging stops, enable Tools->Options->Debugging->Automatically close the console when debugging stops.
+Press any key to close this window . . . \ No newline at end of file