// Display result
for (int i =0; i < result.size(); i++ ){
System.out.println(result.get(i));
System.out.println(result.get(i));
is that correct solution for display duplicated strings ?
is that correct solution for display duplicated strings ?
Under discussion
Comments (3)
- Popular
- New
- Old
You must be signed in to leave a comment
RKVengatesh Enterprise Java Developer at Fragma Data Systems
15 September 2019, 04:29
Because the verification tool checks Expected output for different TestCases......And your solution is printing the Expected output for every Testcases....But it's not the correct way....It won't work in every Tasks...
0
RKVengatesh Enterprise Java Developer at Fragma Data Systems
14 September 2019, 05:08
wow....SmartMind....you are just trying to display the string twice...Tha does'nt mean duplicating it....You have to add the duplicate strings into list and then print the list....Not that easy...Think about it
0
Marcin
14 September 2019, 19:35
so why my solution was approved then ? that is why I am asking because that solution don't seems to be right but task is done ....
+1