Answer:
This is because, the advertisers report the storage space in decimal while the computer reads the storage space in binary.
Explanation:
The advertisers report the storage space in decimal or base 10 because humans count in decimal, whereas the computer reports the storage space in binary or base 2.
Since the computer storage is in bytes and 8 bits equal 1 byte, It is easier to write a storage space of 1 kB as 1000 B but it is actually supposed to be 1024 B(2¹⁰). So, there is a discrepancy of 1024 B - 1000 B = 24 B.
As we go higher, the discrepancy increases. For example, 1 MB is advertised as 1000 kB = 1000000 B but is actually supposed to be 1024 kB = 1024 × 1024 B = 1048576 B. So, there is a discrepancy of 1048576 B - 1000000 B = 48576 B.
So, the actual number of bytes on the storage device is actually less than that reported due to the different number systems in which they are reported in. This discrepancy is less in memory cards or flash drives though in which the stated value of storage capacity might be the actual storage size.
Note that the base 10 or decimal system was chosen by advertiser since this is what consumers understand.
import random
num_rolls = 0
while True:
r1 = random.randint(1, 6)
r2 = random.randint(1, 6)
print("Rolled: " + str(r1) + "," + str(r2))
num_rolls += 1
if r1 == r2 == 1:
break
print("It took you "+str(num_rolls)+" rolls")
I added the working code. You don't appear to be adding to num_rolls at all. I wrote my code in python 3.8. I hope this helps.
THAT IS THE ANSWER 1)requires the new programmers to insert comments o their own
I think that is false I am not 100% sure.
Explanation:
1.By Learning web development Fundamentals.
2.Choose a development specialization.