Tech > Coding Challenges > HackerRank > Prepare > Python > Basic Data Types > List Comprehensions
Problem Link to the original HackerRank problem Let’s learn about list comprehensions! You are given three integers x, y and z representing the dimensions of a cuboid along with an integer n. Print a list of all possible coordinates given by (i, j, k) on a 3D grid where the sum of i + j + k is not equal to n. Here: 0 <= i <= x; 0 <= j <= y; 0 <= k <= z; Please use list comprehensions rather than multiple loops, as a learning exercise. ...