The answer to how many megabytes are in a gigabyte depends on which system you're using. In SI (decimal) terms, there are 1,000 MB in a GB.
In binary terms, which computers often use, there are 1,024 MB in a GB. So the number you'll see can vary slightly depending on whether the measurement is decimal or binary. Both are correct, just used in different contexts.