aboutsummaryrefslogtreecommitdiff
path: root/KnoxFunctions.cpp
diff options
context:
space:
mode:
authorJacobAKnox <[email protected]>2021-11-10 14:29:30 -0800
committerGitHub <[email protected]>2021-11-10 14:29:30 -0800
commita98b35743ab741cea40f6964b3d775d4952e22eb (patch)
tree91de893c1a16607da27ada865e7e5b0c4574926a /KnoxFunctions.cpp
parentMerge pull request #9 from austinsworld15/patch-9 (diff)
parentUpdate KnoxFunctions.cpp (diff)
downloadcst116proj2-1-jacob-k-and-austin-g-a98b35743ab741cea40f6964b3d775d4952e22eb.tar.xz
cst116proj2-1-jacob-k-and-austin-g-a98b35743ab741cea40f6964b3d775d4952e22eb.zip
Merge pull request #8 from austinsworld15/patch-8
Update KnoxFunctions.cpp
Diffstat (limited to 'KnoxFunctions.cpp')
-rw-r--r--KnoxFunctions.cpp11
1 files changed, 9 insertions, 2 deletions
diff --git a/KnoxFunctions.cpp b/KnoxFunctions.cpp
index 6a1cb60..e9345fb 100644
--- a/KnoxFunctions.cpp
+++ b/KnoxFunctions.cpp
@@ -123,8 +123,15 @@ void IsOddEven(int& Number)
cout << "This number is a 0.\n\n";
}
-void FindDigitAtPosition(int Digit, int Position, int& Number)
+void FindDigitAtPosition(int Digit, int Position, string& NumberDigit, char& Numberindex)
{
- cout << "\nThe number you have chosen from before is " << Number << ", what position of that number do you want to see where that digit is outputted?\n";
+ cout << "\nWhat is the number you want to find the digit position of:\n\n";
+ cin >> NumberDigit;
+
+ cout << "what position of that number do you want to see where that digit is outputted ? \n";
cin >> Position;
+
+ Numberindex = NumberDigit[Position - 1];
+
+ cout << "Your digit is " << Numberindex;
}