Kirubha gives a pen to karan on first day. The next day, it will be doubled and so on. Totally how many pens are given in 10 days?


Solution Required by KIRUBHAKARAN DURAIRAJ on 8-Sep-2016 10:37
Kirubha gives a pen to karan on first day. The next day, it will be doubled and so on. Totally how many pens are given in 10 days?
FAJALIA HELI SUNILBHAI on 8-Sep-2016 11:31
n=int(input()) count=1 for i in range(1,n): new_num=count*2 count=count+new_num print(count) ans: 19683
BALAMURUGAN P on 8-Sep-2016 16:40
719
MOHAMED HISHAM on 9-Sep-2016 11:17
2048
KRISHNA PRIYA CHITRAVEL on 9-Sep-2016 11:23
1023
KIRUBHAKARAN DURAIRAJ on 9-Sep-2016 11:28Accepted Solution
Formula = (2^n)-1. Logic: 1st day = 1 =1 =(2^1) -1 2nd day = 1+2 =3 = (2^2) -1 3rd day = 1+2+4=7 = (2^3)-1 .......... 10th day=(2^10)-1 =1023.
KAVIYARASU K on 12-Sep-2016 08:53
1023 is the answer
R MOHAN RAJ on 12-Sep-2016 08:54
1023
A NITHEESHKUMAR on 12-Sep-2016 08:54
1+4=5 is n^1
SHANMUKH ALLURI on 12-Sep-2016 11:03
1023
D.PAVAN KUMAR REDDY on 12-Sep-2016 11:26
1023 is the answer
SANTHOSH D on 12-Sep-2016 21:45
1023
Gogu Rudra Sri Harsha on 12-Sep-2016 22:46
1st day 1 2nd day 2 3rd day 2^2 4th day 2^3 . . . 10th day 2^9 total no. of pens=1+2^1+2^2+......+2^9=2047 pens
Vibhav on 15-Sep-2016 10:41
1023 pens
BALAJI R on 17-Sep-2016 10:26
2047 pens
VETRI A on 17-Sep-2016 12:33
1 2 4 8 16 32 64 128 256 512 ------- tot:1023 ans:1023
ADARSH H S on 17-Sep-2016 14:10
1023
MOVVA NIKHIL on 19-Sep-2016 15:05
1023
KAVIYARASU K on 22-Sep-2016 09:01
what is the answer
Lohith.K on 22-Sep-2016 09:07
ok
Solution
Formula = (2^n)-1. Logic: 1st day = 1 =1 =(2^1) -1 2nd day = 1+2 =3 = (2^2) -1 3rd day = 1+2+4=7 = (2^3)-1 .......... 10th day=(2^10)-1 =1023.