Computer Science Assignment
1. Part of this position involves connecting to databases to extract data. What is/are your suggestion(s) for keeping passwords secure while doing so?
2. You have the following table in a MySQL database:
| id | name | parent |
| 1 | ’home’ | 1 |
| 2 | ‘mobil’ | 1 |
| 3 | ‘motor’ | 1 |
| 147 | ‘toyota’| 2 |
| 160 | ‘bmw’ | 2 |
| 301 | ‘honda’ | 3 |
| 488 | ‘vespa’ | 3 |
Write an SQL-query to produce the following output:
| id | category | subcategory |
| 147| ‘mobil’ | ‘toyota’ |
| 160| ‘mobil | ‘bmw’ |
| 301| ‘motor’ | ‘honda’ |
| 488| ‘motor’ | ‘vespa’ |
Python
1. Assume you have managed to load the expected output from the previous question to a Pandas DataFrame (if you are not familiar with Pandas, show how you would load the output from a .csv file and continue with your preferred method). Write code that gives you only the rows where the category is ‘mobil’.
Expected output (no need to print):
| id | category | subcategory |
| 147| ‘mobil’ | ‘toyota’ |
| 160| ‘mobil’ | ‘toyota’ |
2. What is/are, in your opinion, the best and worst features in Python?
9 years ago
5
- Easy
- I have multiple questions in Finance I need someone to do it.
- Scholarly Discussion: Based on this week’s material and your own relevant research, how would you rate your own neighborhood and the city/town that surrounds it with regard to the concepts presented in this week’s module? Discuss as many environmental fac
- Intro to Graduate Studies
- Workbook
- Qualitative Research Methods and Designs-Peer Response
- Website Analysis
- magz64 only
- Paper
- Rough Draft