Artificial intelligent assistant

print lines if comma seperated fields matching together in another line **Input:** 1,1,10,1 2,1,10,3 3,0,10,1 **Expected Output:** 1,1,10,1 2,1,10,3 So how to print lines if field number `2` and `3` repeated in another line.

Quick'n'dirty method (requiring two passes over the file, the first to count occurrences of `$2,$3`, and the second to print whenever the field combination is non-unique):


$ awk -F, 'NR==FNR{a[$2 FS $3]++; next} a[$2 FS $3] > 1' file file
1,1,10,1
2,1,10,3

xcX3v84RxoQ-4GxG32940ukFUIEgYdPy e3af6d7399fd7718f5b909176d3cbbc0