-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtrials.py
58 lines (32 loc) · 1.06 KB
/
trials.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
"""Python functions for JavaScript Trials 1."""
def output_all_items(items):
for item in items:
print(item)
def get_all_evens(nums):
even_nums = []
for num in nums:
if num % 2 == 0:
even_nums.append(num)
return even_nums
def get_odd_indices(items):
result = []
for idx in range(len(items)):
if idx % 2 != 0:
result.append(items[idx])
return result
def print_as_numbered_list(items):
pass # TODO: replace this line with your code
def get_range(start, stop):
pass # TODO: replace this line with your code
def censor_vowels(word):
pass # TODO: replace this line with your code
def snake_to_camel(string):
pass # TODO: replace this line with your code
def longest_word_length(words):
pass # TODO: replace this line with your code
def truncate(string):
pass # TODO: replace this line with your code
def has_balanced_parens(string):
pass # TODO: replace this line with your code
def compress(string):
pass # TODO: replace this line with your code