Skip to content

Commit e1d5ab8

Browse files
author
unknown
committed
no message
1 parent b9e8d51 commit e1d5ab8

File tree

9 files changed

+41
-37
lines changed

9 files changed

+41
-37
lines changed

Module10Lists/Module10Lists.sln

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
Microsoft Visual Studio Solution File, Format Version 12.00
3-
# Visual Studio 2013
4-
VisualStudioVersion = 12.0.30723.0
3+
# Visual Studio 14
4+
VisualStudioVersion = 14.0.23107.0
55
MinimumVisualStudioVersion = 10.0.40219.1
66
Project("{888888A0-9F3D-457C-B088-3A5042F75D52}") = "Module10Lists", "Module10Lists\Module10Lists.pyproj", "{693EB94A-39ED-4936-9E76-5859D192CC07}"
77
EndProject

Module10Lists/Module10Lists/Module10Lists.pyproj

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<?xml version="1.0" encoding="utf-8"?>
2-
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
2+
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
33
<PropertyGroup>
44
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
55
<SchemaVersion>2.0</SchemaVersion>
@@ -21,8 +21,13 @@
2121
<DebugSymbols>true</DebugSymbols>
2222
<EnableUnmanagedDebugging>false</EnableUnmanagedDebugging>
2323
</PropertyGroup>
24+
<PropertyGroup>
25+
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">10.0</VisualStudioVersion>
26+
<PtvsTargetsFile>$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\Python Tools\Microsoft.PythonTools.targets</PtvsTargetsFile>
27+
</PropertyGroup>
2428
<ItemGroup>
2529
<Compile Include="Module10Lists.py" />
2630
</ItemGroup>
27-
<Import Project="$(MSBuildToolsPath)\Microsoft.Common.targets" />
31+
<Import Project="$(PtvsTargetsFile)" Condition="Exists($(PtvsTargetsFile))" />
32+
<Import Project="$(MSBuildToolsPath)\Microsoft.Common.targets" Condition="!Exists($(PtvsTargetsFile))" />
2833
</Project>

Module13Functions/Module13Functions/helpers.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
12
def getNames():
23
names = ['Christopher', 'Susan', 'Danny']
34
newName = input('Enter last guest: ')

PythonApplication3/PythonApplication3.sln

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
Microsoft Visual Studio Solution File, Format Version 12.00
33
# Visual Studio 2013
4-
VisualStudioVersion = 12.0.30723.0
4+
VisualStudioVersion = 12.0.31101.0
55
MinimumVisualStudioVersion = 10.0.40219.1
66
Project("{888888A0-9F3D-457C-B088-3A5042F75D52}") = "PythonApplication3", "PythonApplication3\PythonApplication3.pyproj", "{C9341719-1D4E-4CE1-B25C-D947C4F5A29B}"
77
EndProject

PythonApplication3/PythonApplication3/PythonApplication3.pyproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<?xml version="1.0" encoding="utf-8"?>
2-
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
2+
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
33
<PropertyGroup>
44
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
55
<SchemaVersion>2.0</SchemaVersion>
Lines changed: 13 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,31 @@
1-
#import the datetime class
1+
# import the datetime class
22
import datetime
33

4-
#declare and initialize variables
4+
# declare and initialize variables
55
strDeadline = ""
66
totalNbrDays = 0
77
nbrWeeks = 0
88
nbrDays = 0
99

10-
#Get Today's date
10+
# Get Today's date
1111
currentDate = datetime.date.today()
1212

13-
#Ask the user for the date of their deadline
13+
# Ask the user for the date of their deadline
1414
strDeadline = input("Please enter the date of your deadline (mm/dd/yyyy): ")
1515

16-
deadline = datetime.datetime.strptime(strDeadline,"%m/%d/%Y").date()
16+
deadline = datetime.datetime.strptime(strDeadline, "%m/%d/%Y").date()
1717

18-
#Calculate number of days between the two dates
19-
totalNbrDays = deadline - currentDate
18+
# Calculate number of days between the two dates
19+
totalNbrDays = int(deadline) - int(currentDate)
2020

21-
#For extra credit calculate results in weeks & days
21+
# For extra credit calculate results in weeks & days
2222

2323
nbrWeeks = totalNbrDays.days / 7
2424

25-
#The modulo will return the remainder of the division
26-
#which will tell us how many days are left
27-
nbrDays = totalNbrDays.days%7
25+
# The modulo will return the remainder of the division
26+
# which will tell us how many days are left
27+
nbrDays = totalNbrDays.days % 7
2828

29-
#display the result to the user
30-
31-
print("You have %d weeks" %nbrWeeks + " and %d days " %nbrDays + "until your deadline.")
32-
29+
# display the result to the user
3330

31+
print("You have %d weeks" % nbrWeeks + " and %d days " % nbrDays + "until your deadline.")

Solutions/Module9EtchASketchChallengeSolution.py

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,29 @@
1-
#Import the turtle drawing library
1+
# Import the turtle drawing library
22
import turtle
33

4-
#Declare variables to hold the information the user enters and set the variables to initial values
4+
# Declare variables to hold the information the user enters and set the variables to initial values
55
penColor = 'black'
66
lineLength = 0
77
angle = 0
88

9-
#Ask user for values for pen color, line length, and angle
10-
#Don't forget to convert the numeric values to integers!
11-
lineLength = int(input("How long would you like to make the line? (specify 0 to stop drawing) " ))
9+
# Ask user for values for pen color, line length, and angle
10+
# Don't forget to convert the numeric values to integers!
11+
lineLength = int(input("How long would you like to make the line? (specify 0 to stop drawing) "))
1212
penColor = input("What pen color would you like to use? (black, blue, red, green): ")
1313
angle = int(input("What angle would you like? (0-360): "))
1414

15-
while lineLength != 0 :
16-
#Draw a line using the values entered by the user
15+
while lineLength != 0:
16+
# Draw a line using the values entered by the user
1717
turtle.color(penColor)
1818
turtle.right(angle)
1919
turtle.forward(lineLength)
20-
21-
#Don't forget to ask for new values inside the loop, otherwise lineLength will never change
22-
#And your loop could execute forever, like mine did the first time I wrote this code!
23-
#Luckily if yo udo accidentally code an infinite loop you can just click the Stop Debugging button in Visual Studio
24-
lineLength = int(input("How long would you like to make the line? (specify 0 to stop drawing) " ))
25-
#If they enter a length of zero then they want to stop drawing, so don't ask for the pen color and angle
26-
if lineLength != 0 :
20+
21+
# Don't forget to ask for new values inside the loop, otherwise lineLength will never change
22+
# And your loop could execute forever, like mine did the first time I wrote this code!
23+
# Luckily if yo udo accidentally code an infinite loop you can just click the Stop Debugging button in Visual Studio
24+
lineLength = int(input("How long would you like to make the line? (specify 0 to stop drawing) "))
25+
# If they enter a length of zero then they want to stop drawing, so don't ask for the pen color and angle
26+
if lineLength != 0:
2727
penColor = input("What pen color would you like to use? (black, blue, red, green): ")
2828
angle = int(input("What angle would you like? (0-360): "))
2929

module4WorkingWithNumbers/module4WorkingWithNumbers.sln

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
Microsoft Visual Studio Solution File, Format Version 12.00
33
# Visual Studio 2013
4-
VisualStudioVersion = 12.0.30723.0
4+
VisualStudioVersion = 12.0.31101.0
55
MinimumVisualStudioVersion = 10.0.40219.1
66
Project("{888888A0-9F3D-457C-B088-3A5042F75D52}") = "module4WorkingWithNumbers", "module4WorkingWithNumbers\module4WorkingWithNumbers.pyproj", "{F5ACBB51-6603-49B5-9C79-6C85BC5C3B4E}"
77
EndProject

module4WorkingWithNumbers/module4WorkingWithNumbers/module4WorkingWithNumbers.pyproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<?xml version="1.0" encoding="utf-8"?>
2-
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
2+
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
33
<PropertyGroup>
44
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
55
<SchemaVersion>2.0</SchemaVersion>

0 commit comments

Comments
 (0)