Hi! I need help with problem 632 - got WA, and cant understand why. My code:
import java.io.IOException;
import java.util.StringTokenizer;
class Main {
static String ReadLn(int maxLg) {
byte lin[] = new byte [maxLg];
int lg = 0, car = -1;
String line = "";
try {
while (lg < maxLg) {
car ...
Search found 3 matches
- Sun Oct 23, 2005 10:22 pm
- Forum: Volume 6 (600-699)
- Topic: 632 - Compression (II)
- Replies: 13
- Views: 6661
- Sun Oct 09, 2005 1:34 am
- Forum: Volume 1 (100-199)
- Topic: 159 - Word Crosses
- Replies: 32
- Views: 6722
- Sun Oct 09, 2005 12:52 am
- Forum: Volume 1 (100-199)
- Topic: 159 - Word Crosses
- Replies: 32
- Views: 6722
159 WA, cant understand why? help me plz!
Here is my code:
import java.io.*;
import java.util.*;
class Main {
static String ReadLn(int maxLg)
{
byte lin[] = new byte [maxLg];
int lg = 0, car = -1;
String line = "";
try {
while (lg < maxLg) {
car = System.in.read();
if ((car < 0) || (car == '\n')) break;
lin[lg++] += car ...
import java.io.*;
import java.util.*;
class Main {
static String ReadLn(int maxLg)
{
byte lin[] = new byte [maxLg];
int lg = 0, car = -1;
String line = "";
try {
while (lg < maxLg) {
car = System.in.read();
if ((car < 0) || (car == '\n')) break;
lin[lg++] += car ...