Search found 10 matches

by vinocit
Fri Jan 30, 2009 11:08 am
Forum: Volume 1 (100-199)
Topic: 120 - Stacks of Flapjacks
Replies: 118
Views: 30294

WA ?

Could any one temme wats wrong with my prog

#include<iostream>
#include<sstream>
#include<stack>
using namespace std;
int min(int a[],int i,int n)
{
int m=i;
for(int j=i;j<n;j++)
if(a[m]>a[j])m=j;
return m;
}
void flip(int a[],int ind,int n)
{
stack<int> sta;
for(int i=ind;i<n;i++)
sta.push ...
by vinocit
Sat Nov 15, 2008 12:25 pm
Forum: Volume 4 (400-499)
Topic: 492 - Pig-Latin
Replies: 213
Views: 49433

Re: 492 WA: tell me why ........................

Could any one say wats wrong with my code. My code gives correct output with the above input

#include<iostream>
using namespace std;
int isvowel(char c)
{
switch(c)
{
case 'a':
case 'A':
case 'e':
case 'E':
case 'i':
case 'I':
case 'o':
case 'O':
case 'u':
case 'U':
return 1 ...
by vinocit
Wed Nov 12, 2008 2:19 pm
Forum: Volume 1 (100-199)
Topic: 111 - History Grading
Replies: 135
Views: 37044

Re: 111 Why WA??

Gr8 understanding Jan thanks :D
by vinocit
Wed Nov 12, 2008 7:30 am
Forum: Volume 4 (400-499)
Topic: 488 - Triangle Wave
Replies: 270
Views: 64411

Re: 488 TLE

Thanks a lot i got AC :D
by vinocit
Wed Nov 12, 2008 7:27 am
Forum: Volume 5 (500-599)
Topic: 591 - Box of Bricks
Replies: 80
Views: 24937

Re: 591

Thanks i got ACed :D
by vinocit
Wed Nov 12, 2008 7:23 am
Forum: Volume 4 (400-499)
Topic: 492 - Pig-Latin
Replies: 213
Views: 49433

WA in 492. Why?

Could any one say whats wrong in my code i am getting WA

#include<iostream>
using namespace std;
int isvowel(char c)
{
switch(c)
{
case 'a':
case 'A':
case 'e':
case 'E':
case 'i':
case 'I':
case 'o':
case 'O':
case 'u':
case 'U':
return 1;
}
return 0;
}
int main()
{
char s[1000 ...
by vinocit
Mon Oct 13, 2008 12:45 pm
Forum: Volume 4 (400-499)
Topic: 488 - Triangle Wave
Replies: 270
Views: 64411

Re: 488 TLE

WA here could any one check this pls
#include<iostream>
using namespace std;
int main()
{
int noofcases;
char *s[9]={"1","22","333","4444","55555","666666","7777777","88888888","999999999"};
int flag=0;
cin>>noofcases;
while(noofcases)
{
noofcases--;
if(!flag)cout<<"\n";
flag=1;
int n,f ...
by vinocit
Mon Oct 13, 2008 11:52 am
Forum: Volume 101 (10100-10199)
Topic: 10189 - Minesweeper
Replies: 418
Views: 124813

Re: 10189 - Minesweeper

Does any one know whats wrong in this?
#include<iostream>
using namespace std;
char check(char a[150][150],int i,int j,int m,int n)
{
if(a [j]=='*')return '*';
int x=0;
if(i>0)
{
if(j>0)
if(a[i-1][j-1]=='*')x++;
if(j<m-1)
if(a[i-1][j+1]=='*')x++;
if(a[i-1][j]=='*')x++;
}
if(i<n-1)
{
if ...
by vinocit
Mon Oct 13, 2008 11:30 am
Forum: Volume 5 (500-599)
Topic: 591 - Box of Bricks
Replies: 80
Views: 24937

Re: 591

Hi does anyone know wats wrong in my code :(
I am getting WA

Code: Select all

Removed after AC
by vinocit
Mon Oct 13, 2008 10:23 am
Forum: Volume 6 (600-699)
Topic: 673 - Parentheses Balance
Replies: 243
Views: 79383

Re: 673 - Parentheses Balance

Hai guys. I dont reply to any post but do keep in mind that empty string has to give out "Yes" . I did this mistake and was looking into it for 3 days

Go to advanced search