wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Data Collection Quiz 1

Total questions: 22

Worksheet time: 11mins

Name
Class
Date
1.

What are the recruitment sites in Vietnam?

a)

Ask Google ...

b)

http://www.vietnamworks.com/

c)

http://careerbuilder.vn/

2.

For each job page, after searching with a certain keyword, how do I get the recruitment information?

a)

On each recruitment, copy-paste information to take into file

b)

Write a program that automatically parse HTML, get the information to retrieve and write down the file

3.
What are the key steps in the Data Science Process?
a)
Data collection
b)
Data visualization
c)
Data discovery and preprocessing
d)
Final decision making
4.
Which of the following are valid methods to collect data?
a)
Use pre-packaged data (CSV, Excel)
b)
Conducting surveys
c)
Use API provided by the website
d)
Copying data from website without permission
5.
Which tools are important for data collection and analysis in Python?
a)
Excel
b)
Jupyter Notebook
c)
Python libraries (requests, pandas, etc.)
d)
Tableau
6.
What should you check before scraping data from a website?
a)
The site’s “robots.txt” file
b)
The site's HTML structure
c)
The JavaScript files used on the site
d)
The site's privacy policy
7.
Why is “garbage in, garbage out” important when collecting data?
a)
Incorrect data leads to incorrect results
b)
Data collected from APIs are always correct
c)
Unreliable data can affect the quality of analysis
d)
Data collected from websites should be trusted
8.
Which are valid Python libraries for scraping data from websites?
a)
requests-html
b)
Selenium
c)
pandas
d)
BeautifulSoup
9.
Which of the following are parts of an HTML tag?
a)
Tag name
b)
Attributes
c)
CSS selectors
d)
Closing tag
10.
What is an advantage of using APIs for data collection over scraping HTML?
a)
APIs are officially provided for external use
b)
APIs are faster to parse than HTML
c)
APIs don’t require knowledge of HTML structure
d)
APIs provide access to all the website's data
11.
Which steps are necessary to collect job posting data from websites like CareerBuilder?
a)
Extract the website’s HTML using Python
b)
Search for specific keywords (e.g., "data scientist")
c)
Manually copy-paste the job postings into a CSV
d)
Write a program to parse HTML and save to CSV
12.
When should you consider creating your own dataset instead of collecting it from external sources?
a)
When the data you need does not exist yet
b)
When you want more control over data quality
c)
When you need a large amount of data
d)
When there are privacy concerns with external data
13.
What is the function of the 'render()' method in the requests-html library?
a)
To process JavaScript on the webpage
b)
To handle APIs
c)
To execute JavaScript and modify the HTML content
d)
To submit forms on a webpage
14.
What are valid reasons for using Selenium in data collection?
a)
Selenium allows for interacting with JavaScript-heavy pages
b)
Selenium can automate browser actions like clicking buttons
c)
Selenium is faster than requests-html for all cases
d)
Selenium can simulate user behavior like form submission
15.
Which of the following Python commands retrieve an HTML tag's text?
a)
tag.html
b)
tag.text
c)
tag.attrs
d)
tag.find()
16.
Which of the following statements about Regular Expressions (Regex) is correct?
a)
Regex can be used to find patterns in strings
b)
Regex is only useful for numeric data extraction
c)
Regex can extract emails from a webpage
d)
Regex is useful for finding words like 'python' or 'R' in job postings
17.
When collecting data from web pages, what should you ensure to avoid legal issues?
a)
The website allows scraping through “robots.txt”
b)
You do not overload the website with too many requests
c)
You collect data that includes personal information
d)
You obtain permission for data collection if required
18.
What are the key components of an API response format like JSON?
a)
A collection of name/value pairs
b)
HTML tags
c)
An ordered list of values (array)
d)
Metadata of the request
19.
Which of the following are correct methods to retrieve data from an API in Python?
a)
Use the requests library to make a GET request
b)
Use the json library to parse the API response
c)
Use pandas to directly read the API output
d)
Use the requests-html library to fetch API data
20.
Which of the following is an advantage of using JSON over XML?
a)
JSON is easier to parse
b)
JSON is more lightweight
c)
JSON provides better structure for machine-to-machine data exchange
d)
JSON is human-readable
21.
What are common challenges when collecting data from websites using JavaScript?
a)
The HTML structure may change dynamically after page load
b)
JavaScript-based content may not be retrieved with basic requests
c)
All JavaScript code is always executed on the server-side
d)
JavaScript content requires additional tools like Selenium
22.
Which Python libraries are typically used for interacting with APIs and parsing JSON data?
a)
requests
b)
json
c)
requests-html
d)
pandas