public class Apples {
public static void main(String args[]){
String base;
int no1 = 72;
int no2 = 75;
base = (String)(no1 + no2);
System.out.println(base);
}
}
The Above code generates error and says that it cannot convert int to String. Why is this so ?
I am a beginner and from my knowledge I guess that type-casting should work here.