Restructuring
This commit is contained in:
13
solutions/CodeChef/easy/HS08TEST/solve.php
Normal file
13
solutions/CodeChef/easy/HS08TEST/solve.php
Normal file
@ -0,0 +1,13 @@
|
||||
<?php
|
||||
while($s=explode(' ',trim(fgets(STDIN)))) {
|
||||
|
||||
if($s[1]%5) {
|
||||
echo $s[1];
|
||||
} else {
|
||||
$new = round($s[1]-$s[1]-0.5,2);
|
||||
if($new)
|
||||
echo $new;
|
||||
else
|
||||
echo $s[1];
|
||||
}
|
||||
}
|
7
solutions/CodeChef/easy/TEST/solve.php
Normal file
7
solutions/CodeChef/easy/TEST/solve.php
Normal file
@ -0,0 +1,7 @@
|
||||
<?php
|
||||
echo fgets(STDIN);
|
||||
while($s = fgets(STDIN)) {
|
||||
if(trim($s) == '42')
|
||||
die;
|
||||
echo $s;
|
||||
}
|
Reference in New Issue
Block a user