From fe2ae46053e19d7cc00a8c597363ef92e74e487b Mon Sep 17 00:00:00 2001 From: baphim <269010393+baphim@users.noreply.github.com> Date: Thu, 3 Sep 2026 01:01:02 -0400 Subject: [PATCH] feat(r-1.3_scratch.py): found a way to add multiple user inputs to a list --- lab-01/r-1.3_scratch.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/lab-01/r-1.3_scratch.py b/lab-01/r-1.3_scratch.py index 9fb34ab..8d5bf16 100644 --- a/lab-01/r-1.3_scratch.py +++ b/lab-01/r-1.3_scratch.py @@ -10,6 +10,7 @@ backwards into the function itself. I need to find a way to end the input loop that I've created.' """ +data = [] y = True while y == True: x = input('Enter a number (type "quit" to stop): ') @@ -20,5 +21,8 @@ while y == True: except: input('Please enter a number: ') else: - if x == str(quit): - break \ No newline at end of file + if x == float(x): + data += [x,] + print(data) + + \ No newline at end of file