0% found this document useful (0 votes)
17 views

02_Performance_Task_1..

The document outlines a performance task for a Python programming assignment, detailing specific steps to modify print() function calls. Each step requires the student to make changes to the code, such as adding empty print() calls, inserting newline characters, and using the 'end' and 'sep' parameters. The task culminates in providing screenshots of the console output after each modification.

Uploaded by

Irold Sanchez
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
17 views

02_Performance_Task_1..

The document outlines a performance task for a Python programming assignment, detailing specific steps to modify print() function calls. Each step requires the student to make changes to the code, such as adding empty print() calls, inserting newline characters, and using the 'end' and 'sep' parameters. The task culminates in providing screenshots of the console output after each modification.

Uploaded by

Irold Sanchez
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Performance Task Python Semantics

02 Performance Task 1

SANCHEZ, IROLD A.

BSIT-3B

1. This program invokes the print() function twice. The two (2) separate lines in the console mean
that print() begins its output from a new line each time it starts its execution.

2. Insert an additional empty print() function invocation between the first two (2) function calls.
This empty print() must produce a new line in the console output. Provide a screenshot of the
console.
3. In your current code, insert \n between the two (2) arguments in the print() function. Provide a
screenshot of the console.

4. Modify the first print() function invocation to use three (3) separate arguments, separated by
commas. Each argument should correspond to a part of the original string. Provide a screenshot
of your code.

5. On your current code from Step 4, add end=" " (containing one space) at the end of the first
print() function invocation. Re-add the second one. Provide a screenshot of the console.
6. For this one, separate the original string of your second print() function invocation per sentence.
This time, add sep="-" at the end of the argument. Note that the value inside the sep can be
changed to anything. Provide a screenshot of the console.

7. Additionally, the end and sep keywords can be used in the same function invocation. Do it on
both functions. Provide a screenshot of the output.

You might also like