Talk is cheap. Show me the code.--Linus Torvalds
Question 0000: Add a red number in the upper right corner of your QQ avatar (or Weibo avatar), similar to the prompt effect of the number of unread messages on WeChat. Similar to the effect in the picture
Question 0001: As an independent developer of Apple Store App, you want to run a limited-time promotion and generate activation codes (or coupons) for your application. How to generate 200 activation codes (or coupons) using Python?
Question 0002: Save the 200 activation codes (or coupons) generated by question 0001 into the MySQL relational database.
Question 0003: Save the 200 activation codes (or coupons) generated by question 0001 into the Redis non-relational database.
Question 0004: Count the number of words appearing in any English plain text file.
Question 0005: You have a directory with many photos, and change their size to be no larger than the resolution of iPhone5.
Question 0006: You have a directory containing your diary for a month, all in txt. In order to avoid the problem of word segmentation, assuming that the contents are all in English, please count the words that you think are the most important words in each diary.
Question 0007: There is a directory with programs you have written. Count how many lines of code you have written. Include blank lines and comments, but list them separately.
Question 0008: For an HTML file, find the text inside.
Question 0009: An HTML file, find the links inside.
Question 0010: Use Python to generate a letter verification code image similar to the one below
Question 0011: The sensitive word text file filtered_words.txt contains the following content. When the user enters a sensitive word, Freedom is printed, otherwise Human Rights is printed.
北京
程序员
公务员
领导
牛比
牛逼
你娘
你妈
love
sex
jiangge
Question 0012: Sensitive word text file filtered_words.txt, the content inside is the same as question 0011. When the user enters a sensitive word, it is replaced with an asterisk *. For example, when the user enters "Beijing is a good city", it becomes "** It’s a good city.”
Question 0013: Use Python to write a picture crawling program to crawl the Japanese girl pictures in this link:-)
Question 0014: The plain text file student.txt is student information. The content (including curly brackets) is as follows:
{
"1":["张三",150,120,100],
"2":["李四",90,99,95],
"3":["王五",60,66,68]
}
Please write the above content into the student.xls file, as shown below:
Question 0015: The plain text file city.txt is city information. The content (including curly brackets) is as follows:
{
"1" : "上海",
"2" : "北京",
"3" : "成都"
}
Please write the above content into the city.xls file, as shown below:
Question 0016: The plain text file numbers.txt, the contents (including square brackets) are as follows:
[
[1, 82, 65535],
[20, 90, 13],
[26, 809, 1024]
]
Please write the above content into the numbers.xls file, as shown below:
Question 0017: Write the contents of the student.xls file in Question 0014 to the student.xml file, such as
As shown below:
<?xml version="1.0" encoding="UTF-8"?>
<root>
<students>
<!--
学生信息表
"id" : [名字, 数学, 语文, 英文]
-->
{
"1" : ["张三", 150, 120, 100],
"2" : ["李四", 90, 99, 95],
"3" : ["王五", 60, 66, 68]
}
</students>
</root>
Question 0018: Write the contents of the city.xls file in Question 0015 to the city.xml file, as shown below:
<?xmlversion="1.0" encoding="UTF-8"?>
<root>
<cities>
<!--
城市信息
-->
{
"1" : "上海",
"2" : "北京",
"3" : "成都"
}
</cities>
</root>
Question 0019: Write the contents of the numbers.xls file in Question 0016 to the numbers.xml file, as follows
Shown:
<?xml version="1.0" encoding="UTF-8"?>
<root>
<numbers>
<!--
数字信息
-->
[
[1, 82, 65535],
[20, 90, 13],
[26, 809, 1024]
]
</numbers>
</root>
Question 0020: After logging into China Unicom's online business hall, select "Self-Service" --> "Detailed Order Query", then select the time period you want to query, click the "Query" button, and at the bottom of the query results page, click "Export" ", a call details .xls file similar to October 1, 2014 to October 31, 2014 will be generated. Write code to make statistics on monthly call time.
Question 0021: Usually, to log in to a website or APP, you need to use a username and password. How are passwords encrypted and stored? Please use Python to encrypt passwords.
Reading material User password storage and Python example
Reading materialHashing Strings with Python
Read Python's safest method to store and retrieve passwords from a database
Question 0022: iPhone 6 and iPhone 6 Plus have already been launched for sale. Please check whether the code you wrote for question 0005 can be reused.
Question 0023: Use Python's Web framework to make a Web version of the guestbook application.
Reading material: What web frameworks are there for Python?
Question 0024: Use Python's Web framework to make a Web version of TodoList application.
Question 0025: Use Python to implement: roar at the computer and automatically open the default website in the browser.
例如,对着笔记本电脑吼一声“百度”,浏览器自动打开百度首页。
关键字:Speech to Text
Reference ideas:
1: Get computer recording-->WAV file python record wav
2: Recording file --> text
STT: Speech to Text
STT API Google API
3:Text-->Computer command