# Khan/khan-exercises

Older
100644 39 lines (35 sloc) 1.23 KB
 af417c3 Add prime numbers Marcia Lee authored May 17, 2011 1 2fb1289 toSentence helper to join arrays with a conjunction spicyj authored May 26, 2011 2 af417c3 Add prime numbers Marcia Lee authored May 17, 2011 3 72418b8 Add meta charset to all HTML pages. jeresig authored Jul 28, 2011 4 07d95d3 spicyj authored Jul 22, 2011 5 Prime numbers 190610b Retool framework, move Math and Graph logic out of khan-exercise.js a… jeresig authored May 18, 2011 6 af417c3 Add prime numbers Marcia Lee authored May 17, 2011 7 8 190610b Retool framework, move Math and Graph logic out of khan-exercise.js a… jeresig authored May 18, 2011 9
25e5b1a marcia authored Sep 21, 2011 10
190610b Retool framework, move Math and Graph logic out of khan-exercise.js a… jeresig authored May 18, 2011 11 getPrime() 12 getOddComposite() 13 getOddComposite() 14 getOddComposite() 15 getEvenComposite() 25e5b1a marcia authored Sep 21, 2011 16 17 shuffle( [ PRIME, WRONG_1, WRONG_2, WRONG_3, WRONG_4 ] ) 190610b Retool framework, move Math and Graph logic out of khan-exercise.js a… jeresig authored May 18, 2011 18
af417c3 Add prime numbers Marcia Lee authored May 17, 2011 19 190610b Retool framework, move Math and Graph logic out of khan-exercise.js a… jeresig authored May 18, 2011 20
21
22

Which of these numbers is prime?

25e5b1a marcia authored Sep 21, 2011 23

\large{CHOICES.join( "," )}

24

PRIME

25
26
• CHOICE
• 190610b Retool framework, move Math and Graph logic out of khan-exercise.js a… jeresig authored May 18, 2011 27
28
29
af417c3 Add prime numbers Marcia Lee authored May 17, 2011 30 190610b Retool framework, move Math and Graph logic out of khan-exercise.js a… jeresig authored May 18, 2011 31
32

A prime number has exactly two factors: 1 and itself.

25e5b1a marcia authored Sep 21, 2011 33

The factors of CHOICE are toSentence( getFactors( CHOICE ) ).

190610b Retool framework, move Math and Graph logic out of khan-exercise.js a… jeresig authored May 18, 2011 34

Thus, PRIME is a prime number.

35
36
af417c3 Add prime numbers Marcia Lee authored May 17, 2011 37 cf02179 Strip trailing whitespace spicyj authored Jun 1, 2011 38
Something went wrong with that request. Please try again.