Блог пользователя kugelblitz1162

Автор kugelblitz1162, история, 4 года назад, По-английски

I recently started coding and being a newbie with no experience whatsoever I got stuck in this error "Source should satisfy regex [^{}]*public\s+(final)?\s*class\s+(\w+).*". If you are also facing the same issue, and have no idea what a regex is, here is a solution that worked for me. All you have to do is start with a public class where you have your main method, and then after the public class, all the other class in the file must be defined after it.

for example:

import **** // any imported package

public class .... { // write a main method here

}

class ..... //here you can define other classes used , just make sure it is after the public class { //define the class you wanna use }

P.S — sorry for my poor English, not a native speaker

Полный текст и комментарии »

  • Проголосовать: нравится
  • -18
  • Проголосовать: не нравится