Skip to content

Instantly share code, notes, and snippets.

@adi-li
Last active June 27, 2016 17:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save adi-li/70caff154c0652cde29e to your computer and use it in GitHub Desktop.
Save adi-li/70caff154c0652cde29e to your computer and use it in GitHub Desktop.
Can I join Snaptee? | Snaptee is recruiting developer πŸ“±πŸ’» https://snaptee.co/jobs/#software-eng | Try to finish the below game to win the opportunity.
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import readline
class Developer(object):
def __init__(self, name, email, skills):
self.name = name
self.email = email
self.skills = skills
self.love_tshirt = True
self.love_programming = True
@property
def qualify_to_join_snaptee(self):
assert self.love_tshirt
assert self.love_programming
required_skills = [skill.lower() for skill in [
'Python', 'Django', 'pip'
'HTML', 'HTML5', 'JavaScript', 'JS', 'CSS3', 'CSS',
'AngularJS', 'jQuery', 'Underscore', 'Underscore.js',
'iOS', 'Objective-C', 'Swift', 'CocoaPods',
'Android', 'Java', 'Gradle',
'Git', 'GitHub',
'AWS', 'EC2', 'S3', 'Cloudfront', 'VPC',
'MVC',
]]
for skill in self.skills:
if skill.strip().lower() in required_skills:
return True
return False
def send_resume_to_snaptee(self):
"""
Send the CV or portfolio to jobs@snaptee.co
Along with the implementation of this part of code will have prior
consideration
For job details, please visit: https://snaptee.co/jobs/
"""
return False
def main():
readline.parse_and_bind("tab: complete")
name = raw_input('What is your name? > ')
email = raw_input('What is your email? > ')
skills = raw_input('Please enter the skills you acquired '
'(comma separted): ').split(',')
developer = Developer(name, email, skills)
if not developer.qualify_to_join_snaptee:
print 'Oops... Seems you need to learn some more skills...'
else:
print 'Great! You are the developer we interested.'
send_resume = raw_input('Send your resume to us? [Y/n]: ')
while send_resume and send_resume.lower() not in ['y', 'yes']:
print 'Are you sure?'
send_resume = raw_input('Please, send your resume to us. [Y/n]: ')
if developer.send_resume_to_snaptee():
print 'Resume sent.'
else:
print 'Fail to send resume...'
print 'Please verify your implementation again.'
if __name__ == '__main__':
main()
@Wei-92
Copy link

Wei-92 commented Jun 27, 2016

For Python 3.x friends, input() replaces raw_input(), raw_input will take the user input and put it in the correct type. Also, remember to use the print() function with Python3.x, including parentheses, instead of the old print command that did not require parentheses. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment