Search found 7 matches

by B_sayem
Wed Aug 27, 2014 7:47 am
Forum: Volume 100 (10000-10099)
Topic: 10038 - Jolly Jumpers
Replies: 445
Views: 74161

Re:10038 - Jolly Jumpers

Why got Wrong Answer #include<iostream> #include <stdlib.h> using namespace std; int main() { int n; cin>>n; int a[n]; for (int i=0;i<n;i++) { cin>>a[i]; } if(n==1) { cout<<"Jolly"; } else{ int dif1 = abs(a[0]-a[1]); int dif2 = abs(a[n-1]-a[n-2]); if (dif1==1) { for (int i=1;i<n-1;i++) { if(abs(a[i...
by B_sayem
Wed Dec 18, 2013 4:51 pm
Forum: Volume 109 (10900-10999)
Topic: 10945 - Mother bear
Replies: 65
Views: 15647

Re: 10945 - Mother Bear WA why? Anyone help me please

Code: Select all

Thanx ,,got AC
:D :D :D
by B_sayem
Mon Dec 16, 2013 8:11 pm
Forum: Volume 4 (400-499)
Topic: 406 - Prime Cuts
Replies: 187
Views: 20657

Re: 406 - Prime Cuts Time Limit exceeded

Can any one Help me why time limit exceeds #include<iostream> #include<stdio.h> using namespace std; int main() { int n,c; while(cin>>n>>c) { int a[n],i=0,count=0; cout<<n<<" "<<c<<":"; for(int j=1; j<=n; j++) { int check=0; for(int k=2; k<j; k++) { if(j%k==0) { check=1; } } if(check==0) { a[i]=j; i...
by B_sayem
Sat Dec 14, 2013 7:14 pm
Forum: Volume 111 (11100-11199)
Topic: 11152 - Colourful Flowers
Replies: 45
Views: 21193

Re: 11152 - Colorful Flowers

Why WA .help me to find error.Thanks yousuf

Code: Select all

Remove after AC.Thanks  :D 
by B_sayem
Sat Dec 14, 2013 5:20 pm
Forum: Volume 112 (11200-11299)
Topic: 11219 - How old are you?
Replies: 117
Views: 32550

Re: [11219 - How old are you?] Wrong Answer!! Plz help me

Why i got wrong ans??please reply. #include<iostream> #include<stdio.h> using namespace std; int main() { //freopen("input.txt", "r", stdin); //freopen("output.txt", "w", stdout); int n,dd1,mm1,yy1,dd2,mm2,yy2,days1,days2,old,check=1; cin>>n; while(n>0) { cout<<endl; cin>>dd1; cin.ignore(); cin>>mm1...
by B_sayem
Thu Dec 12, 2013 9:27 pm
Forum: Volume 123 (12300-12399)
Topic: 12342 - Tax Calculator
Replies: 33
Views: 14763

Re: 12342 Tax Calculator

whats wrong with my program and why i don't use floating point?? #include<iostream> #include<stdio.h> #include<math.h> using namespace std; int main() { unsigned long long int n,amount,check=1,tax; //float tax; cin>>n; while(n>0) { tax=0; cin>>amount; if(amount<=180000) { tax=0; } else { amount=amou...
by B_sayem
Wed Dec 11, 2013 8:00 pm
Forum: Volume 119 (11900-11999)
Topic: 11958 - Coming Home
Replies: 24
Views: 5169

Re: 11958 - Coming Home

Why i got wrong ans??? #include<iostream> #include<stdio.h> using namespace std; int main() { int n,k,ch,cm,ah,am,min1,min2,t,least,check=1; cin>>n; while(n>0) { least=0; cin>>k; cin>>ch; cin.ignore(); cin>>cm; min1=(ch*60)+cm; while(k>0) { int temp; cin>>ah; cin.ignore(); cin>>am; cin>>t; if(((ah*6...

Go to advanced search