Search found 8 matches

by naheed
Fri Nov 14, 2014 5:55 pm
Forum: Volume 114 (11400-11499)
Topic: 11459 - Snakes and Ladders
Replies: 33
Views: 14736

Re: 11459 - Snakes and Ladders

Tried all the test cases available here. Still WA (6 times :( ). #include <cstdio> #include <iostream> #include <map> #define MAX 1000000 using namespace std; int main(){ char player[MAX+2]; int die; int testcase; int numplayers,numsnld,numdierol; map <int,int> cellmp; cin>>testcase; //freopen("a.ou...
by naheed
Sun Nov 09, 2014 5:19 am
Forum: Volume 6 (600-699)
Topic: 612 - DNA Sorting
Replies: 122
Views: 16158

Re: 612 - DNA Sorting

Hi. I have been stuck with my code getting WA multiple times. Tested on the sample inputs & outputs in this thread, but no luck. Here it is: #include <cstdio> #include <cstring> #include <string> #include <cstdlib> #include <map> using namespace std; int strln; map <string,int> mp; int getcount(char...
by naheed
Fri Jul 16, 2010 1:51 am
Forum: Volume 109 (10900-10999)
Topic: 10925 - Krakovia
Replies: 50
Views: 21580

Re: 10925 - Krakovia

Getting WA!!!!! I tried all test cases given by my previous posters.PLEASE HELP. import java.math.BigInteger; import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sn=new Scanner(System.in); BigInteger b[]=new BigInteger[1010]; BigInteger zero=new BigInteger...
by naheed
Mon Jul 12, 2010 11:51 pm
Forum: Volume 5 (500-599)
Topic: 583 - Prime Factors
Replies: 171
Views: 36835

Re: 583 - Prime Factors

REMOVED AFTER AC
by naheed
Fri Jun 18, 2010 12:00 pm
Forum: Volume 4 (400-499)
Topic: 424 - Integer Inquiry
Replies: 96
Views: 20028

424-Integer Inquiry. COMPILATION ERROR!!!!

Why CE in my first java submission??? SMONE PLZ help! import java.util.*; import java.math.*; public class sum { public static void main(String[] args)throws IOException { try{ BigInteger sum; BigInteger zero=new BigInteger("0"); sum=zero; Scanner in=new Scanner(System.in); while(true){ BigInteger ...
by naheed
Fri Jun 18, 2010 11:50 am
Forum: Volume 4 (400-499)
Topic: 424 - Integer Inquiry
Replies: 96
Views: 20028

424-Integer Inquiry. COMPILATION ERROR!!!!

Why CE in this Java program?????Runs farely well in Netbeans,JCreator..No error.PLZ HELP.. import java.util.*; import java.math.*; public class sum { public static void main(String[] args) { try{ BigInteger sum; BigInteger zero=new BigInteger("0"); sum=zero; Scanner in=new Scanner(System.in); while(...
by naheed
Sun Jan 10, 2010 7:29 pm
Forum: Volume 116 (11600-11699)
Topic: 11636 - Hello World!
Replies: 30
Views: 6400

11636 -"HELLO WORLD" getting WA !!!!

The following code is producing wa...:( plz help.. #include <stdio.h> int j=1; int power(int i){ int k; int l=1; for(k=0;k<i;k++) l=2*l; return l; } int main(){ int n,p; while( scanf("%d",&n)==1 && (n!=-1) ){ p=1; while(power(p)<n) p++; if(n==1) printf("Case %d: 0\n",j); else printf("Case %d: %d\n",...
by naheed
Sat Jan 09, 2010 3:40 pm
Forum: Volume 116 (11600-11699)
Topic: 11636 - Hello World!
Replies: 30
Views: 6400

11636 -"HELLO WORLD" getting runtime error!!!

REMOVED AFTER AC.. :D

Go to advanced search