Floors should always be laid perpendicular to floor joists in a house with a plywood subfloor. Incorrect installation can lead to undesired defects such as floor sagging between joists, and also open gaps between the boards can occur.
However, if the surface is made of concrete, then it is recommended to install the floors parallel to the longest wall.