-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlists_dicts_task.py
More file actions
34 lines (27 loc) · 880 Bytes
/
lists_dicts_task.py
File metadata and controls
34 lines (27 loc) · 880 Bytes
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
skills = ["Python", "C++", "Web Development", "Googling" ]
cvSkills = []
cv = {
"name" : input("What is your name? "),
"age" : int(input("How old are you? ")),
"experience" : input ("How many years of experience do you have? "),
"skills" : cvSkills,
}
print ("1- %s\n2- %s\n3- %s\n4- %s\n " %(skills[0],skills[1],skills[2],skills[3]))
skill1 = (int(input("Choose a skill from above: ")) )
skill2 = (int(input("Choose another skill from above: ")) )
cvSkills.append(skills[skill1-1])
cvSkills.append(skills[skill2-1])
def qualified (applicant):
score = 0
if applicant["age"] > 20 and applicant["age"] < 35:
score = score + 5
if cvSkills.count("Googling") == 1:
score = score + 5
if score == 10:
return True
else:
return False
if qualified (cv) == True:
print ("You have been accepted " + cv["name"])
else:
print ("You do not meet the criteria for this job.")