If n is prime, φ(n) equals

Prepare for the GATE General Aptitude and CS Test. Study with comprehensive multiple-choice questions, each equipped with hints and explanations. Master your exam!

Multiple Choice

If n is prime, φ(n) equals

Explanation:
φ(n) counts how many integers from 1 to n are relatively prime to n. If n is prime, every number from 1 to n−1 shares no common factor with n, so gcd(k, n) = 1 for all k in that range. The only number up to n that isn’t coprime with n is n itself, since gcd(n, n) = n. Therefore there are n−1 integers less than n that are coprime to n, so φ(n) = n−1. This is why the correct value is n−1.

φ(n) counts how many integers from 1 to n are relatively prime to n. If n is prime, every number from 1 to n−1 shares no common factor with n, so gcd(k, n) = 1 for all k in that range. The only number up to n that isn’t coprime with n is n itself, since gcd(n, n) = n. Therefore there are n−1 integers less than n that are coprime to n, so φ(n) = n−1. This is why the correct value is n−1.

Subscribe

Get the latest from Examzify

You can unsubscribe at any time. Read our privacy policy