1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
|
LAB 7:
NOTE: In this one output, adding strings, printing strings, removing strings, reprinting strings, and finding a string/substring
in the array was all tested.
OUTPUT:
Please enter 0 to add a value, 1 to print the strings, 2 to remove a string, or any othe rnumber to exit: 0
Enter string you would like to enter: Apple
Please enter 0 to add a value, 1 to print the strings, 2 to remove a string, or any othe rnumber to exit: 0
Enter string you would like to enter: HelloThere
Please enter 0 to add a value, 1 to print the strings, 2 to remove a string, or any othe rnumber to exit: 0
Enter string you would like to enter: Discord
Please enter 0 to add a value, 1 to print the strings, 2 to remove a string, or any othe rnumber to exit: 0
Enter string you would like to enter: Valorant
Please enter 0 to add a value, 1 to print the strings, 2 to remove a string, or any othe rnumber to exit: 0
Enter string you would like to enter: OIT.EDU
Please enter 0 to add a value, 1 to print the strings, 2 to remove a string, or any othe rnumber to exit: 0
Enter string you would like to enter: College
Please enter 0 to add a value, 1 to print the strings, 2 to remove a string, or any othe rnumber to exit: 1
String 1: Apple
String 2: HelloThere
String 3: Discord
String 4: Valorant
String 5: OIT.EDU
String 6: College
Please enter 0 to add a value, 1 to print the strings, 2 to remove a string, or any othe rnumber to exit: 2
What number string would you like to remove? : 4
Please enter 0 to add a value, 1 to print the strings, 2 to remove a string, or any othe rnumber to exit: 1
String 1: Apple
String 2: HelloThere
String 3: Discord
String 4: OIT.EDU
String 5: College
Please enter 0 to add a value, 1 to print the strings, 2 to remove a string, or any othe rnumber to exit: 7
Enter the string you would like to find: OIT
Substring Found!
C:\Users\ansar\source\repos\Lab7Ansari_VFinal\Debug\Lab7Ansari_VFinal.exe (process 20208) 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 . . .
OUTPUT(2):
Please enter 0 to add a value, 1 to print the strings, 2 to remove a string, or any othe rnumber to exit: 0
Enter string you would like to enter: PSU
Please enter 0 to add a value, 1 to print the strings, 2 to remove a string, or any othe rnumber to exit: 0
Enter string you would like to enter: OIT
Please enter 0 to add a value, 1 to print the strings, 2 to remove a string, or any othe rnumber to exit: 0
Enter string you would like to enter: UP
Please enter 0 to add a value, 1 to print the strings, 2 to remove a string, or any othe rnumber to exit: 0
Enter string you would like to enter: OSU
Please enter 0 to add a value, 1 to print the strings, 2 to remove a string, or any othe rnumber to exit: 0
Enter string you would like to enter: UofO
Please enter 0 to add a value, 1 to print the strings, 2 to remove a string, or any othe rnumber to exit: 2
What number string would you like to remove? : 5
Please enter 0 to add a value, 1 to print the strings, 2 to remove a string, or any othe rnumber to exit: 1
String 1: PSU
String 2: OIT
String 3: UP
String 4: OSU
Please enter 0 to add a value, 1 to print the strings, 2 to remove a string, or any othe rnumber to exit: 8
Enter the string you would like to find: OBT
Substring Not Found!
C:\Users\ansar\Source\Repos\cst116-lab7-rayyanansari03\Debug\CST116F2021-Lab7.exe (process 21728) 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 . . .
|