Language: Java

import java.util.Scanner;
??
public class Main {
????????public static void main(String[] args){
????????????Scanner sc = new Scanner(System.in);
????????????int n = sc.nextInt();???????????? 
????????????for(int i=1;i<=n;i++){
????????????????????if(i%3 == 0){
????????????????????????????System.out.printf(" %d",i);
????????????????????} else{
????????????????????????????function(i,i);
????????????????????}
????????????}
????????System.out.println("");
????????}
??????????????
????????????public static void function(int i,int j){
????????????????????if(j%10 == 3){
????????????????????????????System.out.printf(" %d",i);
????????????????????} else if(j>0){
????????????????????????????function(i,j/10);
????????????????????}
????????????}
????????}

Compiler output:
Main.java:2: error: class, interface, enum, or record expected
??
^
Main.java:4: error: illegal start of type
????????public static void main(String[] args){
^
Main.java:5: error: illegal start of expression
????????????Scanner sc = new Scanner(System.in);
^
Main.java:5: error: illegal start of expression
????????????Scanner sc = new Scanner(System.in);
 ^
Main.java:5: error: illegal start of expression
????????????Scanner sc = new Scanner(System.in);
  ^
Main.java:5: error: illegal start of expression
????????????Scanner sc = new Scanner(System.in);
   ^
Main.java:5: error: illegal start of expression
????????????Scanner sc = new Scanner(System.in);
    ^
Main.java:5: error: illegal start of expression
????????????Scanner sc = new Scanner(System.in);
     ^
Main.java:5: error: illegal start of expression
????????????Scanner sc = new Scanner(System.in);
      ^
Main.java:5: error: illegal start of expression
????????????Scanner sc = new Scanner(System.in);
       ^
Main.java:5: error: illegal start of expression
????????????Scanner sc = new Scanner(System.in);
        ^
Main.java:5: error: illegal start of expression
????????????Scanner sc = new Scanner(System.in);
         ^
Main.java:5: error: illegal start of expression
????????????Scanner sc = new Scanner(System.in);
          ^
Main.java:5: error: illegal start of expression
????????????Scanner sc = new Scanner(System.in);
           ^
Main.java:5: error: : expected
????????????Scanner sc = new Scanner(System.in);
                   ^
Main.java:5: error: : expected
????????????Scanner sc = new Scanner(System.in);
                                               ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
 ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
  ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
   ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
    ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
     ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
      ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
       ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
        ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
         ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
          ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
           ^
Main.java:6: error: '.class' expected
????????????int n = sc.nextInt();???????????? 
                ^
Main.java:6: error: : expected
????????????int n = sc.nextInt();???????????? 
                                ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
                                 ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
                                  ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
                                   ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
                                    ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
                                     ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
                                      ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
                                       ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
                                        ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
                                         ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
                                          ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
                                           ^
Main.java:6: error: illegal start of expression
????????????int n = sc.nextInt();???????????? 
                                            ^
Main.java:7: error: illegal start of expression
????????????for(int i=1;i<=n;i++){
^
Main.java:7: error: illegal start of expression
????????????for(int i=1;i<=n;i++){
 ^
Main.java:7: error: illegal start of expression
????????????for(int i=1;i<=n;i++){
  ^
Main.java:7: error: illegal start of expression
????????????for(int i=1;i<=n;i++){
   ^
Main.java:7: error: illegal start of expression
????????????for(int i=1;i<=n;i++){
    ^
Main.java:7: error: illegal start of expression
????????????for(int i=1;i<=n;i++){
     ^
Main.java:7: error: illegal start of expression
????????????for(int i=1;i<=n;i++){
      ^
Main.java:7: error: illegal start of expression
????????????for(int i=1;i<=n;i++){
       ^
Main.java:7: error: illegal start of expression
????????????for(int i=1;i<=n;i++){
        ^
Main.java:7: error: illegal start of expression
????????????for(int i=1;i<=n;i++){
         ^
Main.java:7: error: illegal start of expression
????????????for(int i=1;i<=n;i++){
          ^
Main.java:7: error: illegal start of expression
????????????for(int i=1;i<=n;i++){
           ^
Main.java:7: error: illegal start of expression
????????????for(int i=1;i<=n;i++){
            ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
 ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
  ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
   ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
    ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
     ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
      ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
       ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
        ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
         ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
          ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
           ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
            ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
             ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
              ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
               ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
                ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
                 ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
                  ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
                   ^
Main.java:8: error: illegal start of expression
????????????????????if(i%3 == 0){
                    ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
 ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
  ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
   ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
    ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
     ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
      ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
       ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
        ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
         ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
          ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
           ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
            ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
             ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
              ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
               ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
                ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
                 ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
                  ^
Main.java:9: error: illegal start of expression
????????????????????????????System.out.printf(" %d",i);
                   ^
Main.java:9: error: illegal start of expression
???????????