ssh user@hostname
ex. from Random import randint
sudo apt install python-pip
pip install --upgrade setuptools
pip install --upgrade pip
Return the number of even integers in the given array. Note: the % "mod" operator computes the remainder, e.g. 5 % 2 is 1.
count_evens([2, 1, 2, 3, 4]) → 3
count_evens([2, 2, 0]) → 3
count_evens([1, 3, 5]) → 0
Define a function sumOfList() that takes in a list as a parameter and adds up all of the numbers in the list.
Return the sum, or a string saying "The list is empty" if there are no items in the list.
Note: Use the len(param) function to return the length of the param
Write a function that takes in a string and an integer n, and returns a larger string that is n copies of the original string
Use a for loop, not the string*int
ex. string_times("Hi", 4) == HiHiHiHi
A Fibonacci Sequence is a series of numbers in which each number ( Fibonacci number ) is the sum of the two preceding numbers:
0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55
0 and 1 are the first two Fibonacci numbers, given by default.
Write a function that takes in a number as a parameter, and returns that amount of Fibonacci numbers.