For this Question: You have been given a number N you have to print the number from 1 to N except for the following conditions:-
If the number is a multiple of 3 print "Coca" instead of the number
If the number is a multiple of 5 print "Cola" instead of the number
If the number is a multiple of both 3 and 5 print "CocaCola" instead of the number

<b>Example</b>
A number 5 is given to you. From 1 to 5, it contains 3 and 5 which are multiple of 3 and 5 respectively so they are printed as Coca and Cola respectively. Rest all the numbers i.e 1,2 and 4 are printed as it is.
Hence the output will be:
1 2 Coca 4 ColaThe input contains a single integer N.

<b>Constraints:- </b>
1 &le; N &le; 1000Print N space-separated number or Coca Cola according to the condition.Sample Input:-
3

Sample Output:-
1 2 Coca

Sample Input:-
5

Sample Output:-
1 2 Coca 4 Cola, I have written this Solution Code: import java.util.*;
import java.lang.*;
import java.io.*;

class Main
{
	public static void main (String[] args) throws java.lang.Exception
	{
	
        Scanner sc = new Scanner(System.in);
        int x= sc.nextInt();
        cocacola(x);
	}
static void cocacola(int n){
for(int i=1;i<=n;i++){
        if(i%3==0 && i%5==0){System.out.print("CocaCola ");}
        else if(i%5==0){System.out.print("Cola ");}
        else if(i%3==0){System.out.print("Coca ");}
        else{System.out.print(i+" ");}
}
}
}, In this Programming Language: Java, Now tell me if this Code is compilable or not?