# Exercise 

Write a function 'getSecondLetter' that takes a string argument and returns a list containing every second letter of the input string. 


```python

```

# Exercise

Modify function 'getSecondLetter' so it return a **string** of which contains very second letter of the input string.


```python

```

# Exercise

Given a list of integers, return True if first and last number of a list is same.



```python

```

# Exercise

Given a list of numbers, print only those numbers which are divisible of 5.
Test your function `numList = [10, 20, 33, 46, 55]`
** Hint **: Use modulus function `%` to decide if a number is divisible of 5.



```python

```

# Exercise
Given a list of numbers, return a **list** of only those numbers which are divisible of 5.
Test your function `numList = [10, 20, 33, 46, 55]`
** Hint **: Use modulus function `%` to decide if a number is divisible of 5


```python

```

# Exercise

Return the number of times that the string “Queensland” appears anywhere in the given string.
Test your code on `myQLD="Queensland has many beaches. Every 5th Australian lives in Queensland."`


```python

```

# Excercise 
Given is a dictionary of name and id numbers and a list 
of valid id numbers. Return a list of those id numbers assigned to 
names which are included in the list of valid id numbers.


```python
sampleDict ={'John':47, 'Emma':73, 'Kelly':76, 'Jason':97}
validIdNumber = [47, 64, 69, 37, 76, 83, 95, 97]
```


```python

```

# Exercise
Given a dictionary get all values from the dictionary and add it in a list but don’t add duplicates.


```python
exampleData  ={'jan':47, 'feb':52, 'march':47, 'April':44, 'May':52, 'June':53,'july':54, 'Aug':44, 'Sept':54} 
```


```python

```

# Exercise
Write a Python function to sum all the numbers in a list. Allow an optional argument to set an initial value for the some.  


```python

```

# Exercise
Write a Python function to check whether a number is in a given range. Allow optional parameters for the minimum range value (=0) and maximum range value (=100).


```python

```

# Exercise
Write a function that returns the n-th Fibonacci number $F_n$ (the n-th only!). It is defined
recursively starting from $F_{-1}=1$ and $F_0=0$ and then
\begin{equation}\label{eqFib}
F_n=F_{n-1}+F_{n-2}
\end{equation}
** Note ** First 10 Fibonacci numbers are 1, 2, 3, 5, 8, 13, 21, 34, 55, 89.
** Hint ** You can use recursive function calling.


78a49d34747fa1e78d6086f680f026c72ef2bf86
ipynb
Jupyter Notebook
A_Python/Exercise1.ipynb
uqzzhao/Programming-Geophysics-in-Python
e6e8299116b4698892921b78927b71fc47ee018a
Apache-2.0
2019-11-06T09:08:54.000Z
2021-12-03T08:37:47.000Z
A_Python/Exercise1.ipynb
uqzzhao/Programming-Geophysics-in-Python
e6e8299116b4698892921b78927b71fc47ee018a
Apache-2.0
A_Python/Exercise1.ipynb
uqzzhao/Programming-Geophysics-in-Python
e6e8299116b4698892921b78927b71fc47ee018a
Apache-2.0
2020-11-23T14:16:06.000Z
2022-03-31T14:45:46.000Z
Qwen/Qwen-72B
1. YES
2. YES

