We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
- Prepare
- Java
- Data Structures
- Java Hashset
- Discussions
Java Hashset
Java Hashset
Sort by
recency
|
404 Discussions
|
Please Login in order to post a comment
test case number 5 has error.even code from the editorial can not pass it. please fix this.
Statement "That also implies (a,b) is not same as (b,a)." is not considered on test case 5, e.g. line 8 is "ni kg" and line 192 is "kg ni" but is not considered as a unique pair so it's not counted on expected output.
PASSES ALL 6 TESTCASES
import java.io.; import java.util.; import java.text.; import java.math.; import java.util.regex.*;
public class Solution {
public static void main(String[] args) { Scanner s = new Scanner(System.in); int t = s.nextInt(); String [] pair_left = new String[t]; String [] pair_right = new String[t];
} }
The issue with test case 6 is how the problem is formulated:
The original problem statement says that order matters, but test case 6 behaves as if order does not matter.
public class Solution {
}