Search found 8 matches

by ante
Wed Apr 24, 2002 6:25 pm
Forum: Volume 101 (10100-10199)
Topic: 10110 - Light, more light
Replies: 76
Views: 39730

UNSIGNED PROBLEM

I didn't read problem carefully enough :( , 2^32 - 1 is 4,294,967,295 and this must be UNSIGNED int .

Thanx anyway !
by ante
Wed Apr 24, 2002 4:17 pm
Forum: Volume 101 (10100-10199)
Topic: 10110 - Light, more light
Replies: 76
Views: 39730

More Pascal Light also

I tried this in Pascal but it didn't work also, i need to check if N has integer square root .
Please help !

[pascal]
program p10110;
var
n: integer;
begin
while not eof(input) do
begin
readln(n);
if (n = 0) then break;
if frac(sqrt(n))<0.000001 then writeln('yes') else
writeln('no');
end ...
by ante
Tue Apr 23, 2002 6:58 pm
Forum: Volume 101 (10100-10199)
Topic: 10110 - Light, more light
Replies: 76
Views: 39730

10110 More Light's Please

Why I receive WA ??? What's the problem ???

[cpp]
#include<stdio.h>
#include<math>
void main()
{
int n;
while (1)
{
scanf("%d",&n);
if (n == 0) break;
if (((int)sqrt(n))==sqrt(n))
printf("yes\n");
else
printf("no\n");
}
}
[/cpp]

Thanx in advance 8)
by ante
Mon Apr 08, 2002 10:57 pm
Forum: Volume 102 (10200-10299)
Topic: 10205 - Stack 'em Up
Replies: 60
Views: 33154

10205 - Stack 'em Up

I'm wondering if I 'm handleing input correctly, this is my code and problem has multiple test cases


var
Tests, TestNO: integer;
br: byte;
Niz: string

Procedure ReadShuffle(br: byte);
var
n, i: byte;
begin
for n := 1 to br do
For i := 1 to 52 do
if i=52 then
readln(shuffle[n, i])
else ...
by ante
Fri Apr 05, 2002 11:14 am
Forum: Volume 102 (10200-10299)
Topic: 10252 - Common Permutation
Replies: 150
Views: 73275

I give up from this problem and P.E. response, i tried many methods for output but none of them works,
if anyone has AC whthout P.E would you please send it to me at mailto: anblasko@globalnet.hr
Thanx in advance
by ante
Tue Apr 02, 2002 3:03 am
Forum: Volume 102 (10200-10299)
Topic: 10252 - Common Permutation
Replies: 150
Views: 73275

I solved it in C++ and still P.E.
Does anyone knows how to solve it without P.E

P.S:
Thanx Stefan for C++ tips.
by ante
Wed Mar 20, 2002 4:41 pm
Forum: Volume 102 (10200-10299)
Topic: 10248 - The Integer All-time Champ
Replies: 11
Views: 9676

10248 - The Integer All-time Champ

Hi !
is this correct string length for these three inputs

1 99 ===> length is 99
30 80 ===> length is 76
1 50 ===> length is 66
by ante
Wed Mar 20, 2002 4:35 pm
Forum: Volume 102 (10200-10299)
Topic: 10252 - Common Permutation
Replies: 150
Views: 73275

for i=1 to length(str1)
for j=1 to length(str2)
begin
if str1 =str2[j] then
begin
delete char at j position in str2
add char at i position to temporary string
exit j loop
end
end
write alphabet. sorted temporary string

I got P.E. in Pascal, if anyone knows what's the catch ?

P.S: now ...

Go to advanced search