Final answer:
The first problem requires writing a function to calculate total work hours from file data for a specific employee, handling file non-existence. The second involves creating a function that identifies the most populous cities in a given region and year by accessing and processing information from a CSV file.
Step-by-step explanation:
Problem A is about writing a function called total_time, which reads a file containing employee work hours and calculates the total hours worked by a specified employee. The function takes two parameters: a string representing the filename (fname) and another string representing the employee's name (employee). It returns a float which is the sum of hours, or 0.0 if the employee did not work any hours, or -1.0 if the file does not exist.
For Problem B, the task is to write a function called most_populous that reads data from a 'cities.csv' file and returns a list of the most populous cities from a specified region for a given year. The function needs to handle strings for both the year and region parameters. By analyzing the CSV data, the function returns a list of city names that match the criteria.