Question

Hey guys, Question with PYTHON I have this simple code and I keep getting 13 for...

Hey guys, Question with PYTHON

I have this simple code and I keep getting 13 for the answer but the answer is actually 13.33. Can someone show me how to get python to return this value! Thanks !

CN = 75
S = (1000/CN)
print S

0 0
Add a comment Improve this question Transcribed image text
Answer #1

This is correct code. If you modify your code with S=(1000//cn) then you will get 13.

cn=75
s=(1000/cn)
print (s)

here i submit screenshot

mo25.03.p Dat ra de Eile Edit Format Bun Options Window Help cn-75 s (1000/cn) print (s) Ln: 4 Col:0 ENG 16:47 INTL 25-03-201Python 3.7.1 Shell Eile Edit Shell Debug ptios Window Help Python 3.7.1 (v3.7.1:260ec2c36a, Oct 20 2018, 14:05:16) [MSC v.191you have any query then plz ask me without any hesitation in the comment section below, if you like my answer then please thumbs up for the answer, before giving thumbs down please discuss the question it may possible that we may understand the question different way and we can edit and change the answers if you agree, thanks :)

Add a comment
Know the answer?
Add Answer to:
Hey guys, Question with PYTHON I have this simple code and I keep getting 13 for...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • in python would you please help me to keep this code as in a simple and...

    in python would you please help me to keep this code as in a simple and easy code to follow please I want the code to run like first line of the letters ['B', 'C', 'D', 'BC', 'CB', 'BD', 'BCB', 'CBD', 'BCBD'] ['B', 'BC', 'BCB', 'BCBD', 'C', 'CB', 'CBD', 'BD', 'D'] word="BCBD" lst=[] for i in range(len(word)): for j in range(i+1,len(word)+1): if word [i:j] not in lst: lst.append(word[i:j]) print(lst)

  • Hey guys. I am new to coding. And I need your help in answering this problem...

    Hey guys. I am new to coding. And I need your help in answering this problem for me. You have to answer this problem using only C++ programming language. Thanks. "Write a program that asks the user for an integer value, num. The program calculates the total number of factors of num. For example, if the user enters 12, the program should print out 6 (1,2,3,4,6,12)."

  • I'm trying to run the code in Python below and keep getting invalid syntax. What's wrong?...

    I'm trying to run the code in Python below and keep getting invalid syntax. What's wrong? Thanks for any help! def even(n): if n%2==0 #Enter a Number def main(): n=int(input("Enter a number: ")) #If even print "Number is even" if(even(n)): print("The number is even") #If odd print "Number is odd" else: print("The number is odd") main() #Call the main function

  • Python help! I need help getting my code to increment the value. It keep calculating the...

    Python help! I need help getting my code to increment the value. It keep calculating the range over the same number and not moving up! this is the question Write a program named q1() that prompts the user for the starting and ending distance in Kilometers (km), and an increment value. It should then print the conversion table showing values for Kilometers, Miles (M) and Feet (ft). Each value should be displayed as they are calculated. and this is the...

  • Hey guys. I know the answer, but can you help me with understanding a step by...

    Hey guys. I know the answer, but can you help me with understanding a step by step process of how to get the answer! #1 .data myPtrCheck BYTE 12h, 34h, 56h, 78h, 90h, ABh, CDh, EFh .code ... mov eax, DWORD PTR [myPtrCheck+2] EAX contains what value, in hexadecimal? answer is AB907856h #2 Suppose that you are given the following partial data segment: .data myPtrCheck BYTE 12h, 34h, 56h, 78h, 90h, ABh, CDh, EFh .code ... mov eax, DWORD PTR...

  • Hi! I'm hoping someone can help me with this question. I keep getting the wrong answer...

    Hi! I'm hoping someone can help me with this question. I keep getting the wrong answer when calculating, so I am trying to understand where I am going wrong. Thanks! D 1. For the balanced redox reaction: 3 Mn2+ (aq) + 2Al(s) 3 Mn(s) + 2 A13+ (aq) Calculate Eºcell A. +1.59 V B. +0.93 V C. +0.48 V D. -0.32V E. -0.19 V А B с D E

  • Hey guys I need help understanding what's going on in the following for reactions. Any detail...

    Hey guys I need help understanding what's going on in the following for reactions. Any detail you can provide to help me understand them better would be much appreciated. Here are some specific questions I have about them. Top left: I want to know what those reagents are actually doing, like each one of them what's their purpose in the reaction (including the heat, the H2NNH2, the KOH and also the long one at the bottom)? Why does the ketone...

  • I have a problem that I have worked several times, and I keep getting the same...

    I have a problem that I have worked several times, and I keep getting the same answer, but am told it is wrong. Can someone help me understand what I am doing wrong? Here is the problem: I am getting .22 A random sample of n = 16 scores is obtained from a population with a mean of µ = 45. After a treatment is administered to the individuals in the sample, the sample mean is found to be M...

  • I have the attached code and keep getting an unexpected indent error on the last line,...

    I have the attached code and keep getting an unexpected indent error on the last line, how can I fix this? 1 import urllib 2 import re 3 url raw_input('Enter the URL:') 4 req request (url) 5 while True: 6 try: counts dict() fhandurllib.urlopen (req) for line in fhand: words line.split) for word in words: 10 counts[word] counts.get(word,0) 1 12 13 14 15 16 17 print(counts) data - count.getlength(512) if(len (data) < 1): break print data

  • while trying to run this in python, i keep getting the error TypeError: int() can't convert...

    while trying to run this in python, i keep getting the error TypeError: int() can't convert non-string with explicit base. any way to fix this? def binaryToDecimal(n): return int(n,2) if __name__ == '__main__': num3 = int(input("Enter value to be converted: ")) print(binaryToDecimal(num3))

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT