ENG  RUS Timus Online Judge Online Judge
Problems
Authors
Online contests
Site news
Webboard
Problem set
Submit solution
Judge status
Guide
Register
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board

## Discussion of Problem 1433. Diamonds

Why WA 12? Help!
Posted by Ignat Zakrevsky 19 Nov 2007 16:00
Var a,b:array [0..3] of string;
c,d:string;
N,I,J:LongInt;
P:Boolean;
Begin
P:=FALSE;
A:=C;A:=C;A:=C;A:=C;
B:=D;B:=D;B:=D;B:=D;

If A=B Then
If ((A=B) and (A=B) and (A=B)) or
((A=B) and (A=B) and (A=B)) or
((A=B) and (A=B) and (A=B))
Then P:=True;

If A=B Then
If ((A=B) and (A=B) and (A=B)) or
((A=B) and (A=B) and (A=B)) or
((A=B) and (A=B) and (A=B))
Then P:=True;

If A=B Then
If ((A=B) and (A=B) and (A=B)) or
((A=B) and (A=B) and (A=B)) or
((A=B) and (A=B) and (A=B))
Then P:=True;

If P=True Then Writeln('equal')
Else Writeln('different');
End.

Say me why this program not work?

Edited by author 01.12.2007 21:32

Edited by author 01.12.2007 21:33
Re: Why WA 12? Help!
Posted by Kaki 15 Dec 2012 00:14
What if A = B?