Hi,
Does anyone have any idea how to compare the length of the two strings? Thank you. A.
package fr.codegym.task.task04.task0421;
/*
Jen ou Jen ?
*/
import java.io.*;
public class Solution {
public static void main(String[] args) throws Exception {
//écris ton code ici
BufferedReader lecteur = new BufferedReader(new InputStreamReader(System.in));
String a = lecteur.readLine();
String b = lecteur.readLine();
if (a == b.intern())
System.out.println("Les noms sont de la même longueur");
else
if (a.equals(b))
System.out.println("Les noms sont identiques");
else
;
}
}