Answer:
def calculate_pay(total_worked_hours, rate_per_hour):
if total_worked_hours > 40:
return (40 * rate_per_hour) + ((total_worked_hours - 40) * 2 * rate_per_hour)
else:
return total_worked_hours * rate_per_hour
Explanation:
- Create the calculate_pay function that takes 2 parameters.
- Inside the function check whether the total_worked_hours is greater than 40 and then return the pay by calculating with the help of formula for work over 40 hours.
- Otherwise return the pay by multiplying the total_worked_hours with rate_per_hour.
Answer:
B) computeValue(10);
Explanation:
Given
Header: void computeValue(int value)
Required
Determine the valid call
To call a function from another function or from the main, the following syntax has to be used.
<em>function-name(parameter-1, parameter-2, parameter-3,.....,parameter-n);</em>
<em />
In the function header given:, the following can be observed:
- The function name is computeValue
- It has only one parameter and it is of type integer
So, to call the function; we make use of computeValue(10);
Where 10 represents the value of the parameter (i.e. argument)
For the view of Exercise 4.18, explain why the database system would not allow a tuple to be inserted into the database through this view.
For reference
For the database of Figure 4.12, write a query to find the ID of each employee with no manager. Note that an employee may simply have no manager listed or may have a null manager. Write your query using an outer join and then write it again using no outer join at all.
OUTER JOIN
select e.ID from employee e left outer join manages m on e.ID = m.ID
where m.manager_id is null;
NO OUTER
select e.ID from employee e where e.ID not in (select m.ID from manages m) or e.ID in (select m.ID from manages m where m.manager_id is null);
Make your own name for your anime and your own powers it’s really not that hard bud
Ask someone who knows about this stuff this is weird I would say look it up maybe