Do trial and error maybe?
rearrange to get m= or
input integers in n, and see if it is an integer.
however this is a very simple one, and to me the solution is obvious just by doing 8m=7n
BUT there are an infinite amount of solutions, just multiply and n by an integer