more_14

Given a list of ints, return true if the number of 1’s is greater than the number of 4’s

This exercise was taken from codingbat.com and has been adapted for the Python language. There are many great programming exercises there, but the majority are created for Java.

Test 1

Input:

[1, 4, 1]

Output:

True

Test 2

Input:

[1, 4, 1, 4]

Output:

False

Test 3

Input:

[1, 1]

Output:

True

Test 4

Input:

[1, 6, 6]

Output:

True

Test 5

Input:

[1]

Output:

True

Test 6

Input:

[1, 4]

Output:

False

Test 7

Input:

[6, 1, 1]

Output:

True

Test 8

Input:

[1, 6, 4]

Output:

False

Test 9

Input:

[1, 1, 4, 4, 1]

Output:

True

Test 10

Input:

[1, 1, 6, 4, 4, 1]

Output:

True

Test 11

Input:

[]

Output:

False

Test 12

Input:

[4, 1, 4, 6]

Output:

False

Test 13

Input:

[4, 1, 4, 6, 1]

Output:

False

Test 14

Input:

[1, 4, 1, 4, 1, 6]

Output:

True