记录详情

Compile Error

./Main.java:2: error: class StringShift is public, should be declared in a file named StringShift.java
public class StringShift{
       ^
./Main.java:3: error: cannot find symbol
	public static string shift(String s) {
	              ^
  symbol:   class string
  location: class StringShift
./Main.java:4: error: array required, but String found
		char tmp=s[0];
		          ^
./Main.java:6: error: array required, but String found
			s[i-1]=s[i];
			 ^
./Main.java:6: error: array required, but String found
			s[i-1]=s[i];
			        ^
./Main.java:7: error: array required, but String found
		s[s.length()-1]=tmp;
		 ^
./Main.java:13: error: cannot find symbol
		string []ss;
		^
  symbol:   class string
  location: class StringShift
./Main.java:17: error: cannot find symbol
		for(i=0;i<ss.length();i++)
		    ^
  symbol:   variable i
  location: class StringShift
./Main.java:17: error: cannot find symbol
		for(i=0;i<ss.length();i++)
		        ^
  symbol:   variable i
  location: class StringShift
./Main.java:17: error: cannot find symbol
		for(i=0;i<ss.length();i++)
		                      ^
  symbol:   variable i
  location: class StringShift
./Main.java:22: error: cannot find symbol
				if(ss[i].compareTo(ss[j])>0);
				      ^
  symbol:   variable i
  location: class StringShift
11 errors
[Hydro](https://hydro.ac)提供评测服务

信息

递交者
类型
自测
题目
P1301 H. String Shifting
语言
Java
递交时间
2021-11-21 16:23:29
评测时间
2021-11-21 16:23:29
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes