Search found 4 matches

by lasia
Sun Mar 17, 2013 9:29 am
Forum: Volume 5 (500-599)
Topic: 514 - Rails
Replies: 79
Views: 37944

514 - RE

#include<stdio.h>
#include<string.h>
#define MAXN 1000 + 10
int n, target[MAXN];
char string[MAXN];

void game(int n)
{
int stack[MAXN], top = 0;
int A = 1, B = 1;
int ok = 1;
while(B <= n) {
if(A == target[B]){ A++; B++; }
else if(top && stack[top] == target[B]){ top--; B++; }
else if(A ...
by lasia
Thu Mar 07, 2013 9:14 am
Forum: Volume 5 (500-599)
Topic: 537 - Artificial Intelligence?
Replies: 76
Views: 22528

Re: 537 got WA, please help

brianfry713 wrote:Your code doesn't match the sample I/O.
It did match on my pc though. Would you please paste the output on your machine? Thank you.
by lasia
Tue Mar 05, 2013 11:10 pm
Forum: Volume 5 (500-599)
Topic: 537 - Artificial Intelligence?
Replies: 76
Views: 22528

Re: 537 got WA, please help

brianfry713 wrote:Print a blank line after the last test case.
I did but still WA. Any other suggestion?
by lasia
Tue Mar 05, 2013 11:36 am
Forum: Volume 5 (500-599)
Topic: 537 - Artificial Intelligence?
Replies: 76
Views: 22528

537 got WA, please help

Got WA lots of times but still cannot figure out. Please help. Thank you in advance!

#include<stdio.h>
#include<string.h>
#define MAXN 500+2

char line1[MAXN];
double num[2] = {0.0, 0.0};
char unit[2] = {'0', '0'};
char prefix[2] = {'0', '0'};

void dataProcess(char unit1, double num1, char unit2 ...

Go to advanced search