Answer:
def nametag(first_name, last_name):
return("{} {[0]}.".format(first_name, last_name))
print(nametag("Jane", "Smith"))
# Should display "Jane S."
print(nametag("Francesco", "Rinaldi"))
# Should display "Francesco R."
print(nametag("Jean-Luc", "Grand-Pierre"))
# Should display "Jean-Luc G."
Explanation:
First you must think about that the question ask about the first letter for last_name, remember [0] is the first letter not [1], the other part is about format function and its order
Answer:
<u><em>(1) Spam, (2) Trash.</em></u>
Explanation:
"<u><em>Emails are unsolicited-" is another word for spam</em></u> lol. <u><em>And then "Others she doesn’t need." is, again, another word for trash</em></u>. I mean if you don't need it is trash then.
WELP I hope I helped you even tho this is late. Ahem, well. <u><em>Stay awesome!</em></u>
You have to pick a gift. Mostly it's a dollar. Then you can go back and continue.
Answer:
B. void setAttributeOne(int newAttributeOne)
{
attributeOne = newAttributeOne
}
Explanation:
The class has two public attributes : int attributeOne and String attributeTwo.
The appropriate setters for these attributes will be as follows:
void setAttributeOne(int newAttributeOne)
{
attributeOne = newAttributeOne
;
}
void setAttributeTwo(int newAttributeTwo)
{
attributeTwo = newAttributeTwo;
}
The highlighted code corresponds to option B among the given options. So option B is the correct setter for attributeOne.
Answer:
input number of days d
↓
calculate number of months as d/30 rounded up
↓
display number of months
↓
calculate number of hours as d * 24
↓
display number of hours
Explanation:
The flowchart is pretty straightforward since there are no decisions to make.