Last answered:

02 Dec 2021

Posted on:

01 Dec 2021

1

Printing a data list using the print function

Please when i try to run the code "Print(data_set.remove(21))" it keeps returning none on the code. please any explanation for this. 21 is included in the data_set
Thanks.

1 answers ( 0 marked as helpful)
Instructor
Posted on:

02 Dec 2021

1

Hey Abdulgafar,

Thank you for your question!

It returns None since you are not trying to print out data_set but rather data_set.remove(21) which is of type None:
image.png
Make sure you execute the code in the following way:
image.png
Hope this helps!

Kind regards,
365 Hristina

Submit an answer