harrisonlabollita / MagShapeAni.jl

Calculate the magnetic shape anisotropy for a given lattice and physical constants
0 stars 0 forks source link

Combine some nested loops #2

Closed lanceXwq closed 3 years ago

lanceXwq commented 3 years ago

IMHO, this reads better than two consecutive for loops.

lanceXwq commented 3 years ago

The manual suggests this is mostly the same as the nested loop. The only notable difference is, in this case, one break will break both loops.