Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Q
Quizzer
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
thomaskmatthew
Quizzer
Commits
fdc45e19
Commit
fdc45e19
authored
3 years ago
by
thomaskmatthew
Browse files
Options
Downloads
Patches
Plain Diff
print statment now keeps in track of the total score
parent
786f9f60
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
main.py
+3
-1
3 additions, 1 deletion
main.py
with
3 additions
and
1 deletion
main.py
+
3
−
1
View file @
fdc45e19
...
...
@@ -110,8 +110,10 @@ class QuizzerApp(App):
question
=
self
.
questions
[
-
1
]
if
len
(
self
.
questions
)
>
0
else
QuizzerApp
.
DEFAULT_QUESTION
self
.
paused
=
True
self
.
correct
=
answer
==
question
[
2
]
if
self
.
correct
:
print
(
"
You got it correct
"
)
self
.
score
+=
1
print
(
f
'
You got it correct, number of right are:
{
self
.
score
}
'
)
Clock
.
schedule_once
(
lambda
delta
:
self
.
unpause
(),
PAUSE_TIME
)
def
unpause
(
self
):
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment