I was well versed in python programming.
One morning a question was shooted at me by one of the blog followers
What is the output of 6/2 , 6//2 , 6%2
I was able to provide the answer for 6%2 as zero, but confused to answer 6/2 and 6//2
/ Division # Provide floating point as output
// Floor division #Rounds the result down to the nearest whole number
% Modulus # Remainder
No comments:
Post a Comment