You are not logged in. Please login at www.codechef.com to post your questions!

×

bytelandian questions doubt

**can you please tell how can i reduce my time limit for this code (BYTELANDIAN COINS CODE)

def profit(a): if a<12: return a else: b1=int(a/2) b2=int(a/3) b3=int(a/4) sum = (profit(b1)+profit(b2)+profit(b3)) return sum

for i in range(0,10): n=int(input("enter the value of n")) print("american dollars =",profit(n))

asked 28 Sep '18, 12:04

coder_ag's gravatar image

2★coder_ag
112
accept rate: 0%

Better to share a link to your code: https://www.codechef.com/viewsolution/20356920

But to show code properly use the 101/010 button with the code highlighted when editing.

(28 Sep '18, 12:58) joffan5★
toggle preview
Preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported
  • mathemetical formulas in Latex between $ symbol

Question tags:

×2,718
×518
×204
×78
×40

question asked: 28 Sep '18, 12:04

question was seen: 63 times

last updated: 28 Sep '18, 12:58