forked from CSSE120StartingCode/IntroductionToPython
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathm2_todo_and_commit_push.py
More file actions
123 lines (118 loc) · 5.64 KB
/
m2_todo_and_commit_push.py
File metadata and controls
123 lines (118 loc) · 5.64 KB
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
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
###############################################################################
#
# This line is a COMMENT -- a note to human readers of this file.
# When the Python interpreter RUNS (i.e. EXECUTES) a program, it ignores
# everything from a # (hash) mark to the end of the line with the # mark.
#
# We call files that have Python code in them MODULES.
# Line 15 of this module (look at it now) prints (displays) the STRING
# Hello, World
# on the Run window.
#
# Anything surrounded by quote marks (single or double) is a STRING.
#
###############################################################################
print("Hello, World")
###############################################################################
# TODO: 1.
# (Yes, that means for YOU to DO things per these instructions:)
# _
# Run this module by right clicking anywhere in this window
# and selecting
# Run 'name of file'
# Or, use the keyboard shortcut: Control + Shift + Function-F10.
# _
# After running, find the Run window and confirm that
# Hello, World
# did indeed get printed (displayed) on that window.
###############################################################################
###############################################################################
# TODO: 2.
# Notice the small horizontal BLUE bars on the scrollbar-like thing
# on the right. Each blue bar indicates a thing "to do" in this module.
# _
# a. You can use the blue bars to go from one _TODO_ to the next
# by clicking on the blue bars. ** Try that now. **
# _
# b. When you have completed a _TODO_, you should change the word
# _TODO_ (ignore the underscores on this line)
# to
# DONE
# Try it now on line 18 above, and note that its blue bar on the
# scrollbar-like thing to the right goes away soon thereafter.
# _
# If you change each _TODO_ to DONE like this, you can tell when you
# have finished all the exercises in a module -- there will be no
# blue bars left on the scrollbar-like thing to the right.
# _
# You have now completed _TODO_ #2, so change its _TODO_ on line 32 to DONE
# (and likewise for all forthcoming TODOs in this course).
###############################################################################
###############################################################################
# TODO: 3.
# Add another print statement below this comment.
# It should print any string that you want (but keep it polite and G-rated!)
# _
# Test your code by re-running this module, either by proceeding
# as you did when you ran this module the first time,
# or by pressing the green rightward-pointing triangle
# that is the "Play" button on the toolbar at the top of this window.
# Look at the Run window to be sure that your string printed as expected.
###############################################################################
###############################################################################
# TODO: 4.
# Add yet another print statement, putting it below this comment.
# This one should print the *product* of 3,607 and 34,227.
# Let the computer do the arithmetic for you (no calculators!).
# You do NOT have to use strings for this, so no quotation marks!
# _
# TEST your code by re-running this module, then asking someone
# whom you trust:
# What number did your print display for this _TODO_?
# (HINT: It is an INTERESTING number.) Get help if your value is wrong.
###############################################################################
###############################################################################
# TODO: 5.
# Look at the list of files in the Project window (to the left).
# Note that this file:
# m2_todo_and_commit_push.py
# is now displayed in BLUE (or the color you may have set for changed files).
# _
# The BLUE font color means that you have made changes to this file which
# have not yet been COMMITTED to version control and PUSHED to the cloud.
# _
# COMMIT and PUSH your work by:
# 1. Select VCS from the menu bar (above).
# 2. Choose Commit from the pull-down menu that appears.
# 3a. In the Commit Changes window that pops up:
# - Just this once, type a short message in the
# Commit Message
# sub-box, e.g. "Done."
# It truly does not matter what message you put (but it WILL matter
# when you work with teammates later in the course). Subsequent
# commits will auto-apply whatever message you use this time.
# 3b: In that same Commit Changes window that pops up:
# - Press the Commit and Push button.
# (Note: If you see only a Commit button:
# - HOVER over the Commit button
# (in the lower-right corner of the window)
# - CLICK on Commit and Push.)
# _
# COMMIT adds the changed work to the version control system
# on your COMPUTER. PUSH adds the changed work into your
# repository in the "cloud".
# _
# Always PUSH (in addition to the COMMIT) so that your work
# is backed-up in the cloud. If you COMMIT but forget to PUSH,
# you can subsequently do the PUSH by:
# VCS ~ Git ~ Push...
# _
# Oh, one more thing:
# Do you have any blue bars on the scrollbar-like thing to the
# right? If so, click on each blue bar and change its _TODO_ to
# DONE and then run the module (to make sure you did not break
# anything) and COMMIT-and-PUSH again.
# _
# You can COMMIT-and-PUSH as often as you like.
# DO IT FREQUENTLY; AT LEAST once per module.
###############################################################################