EM2301. Practical Class 3
EM2301. Practical Class 3
Excercise 1
SCORE
Regional
ID NAME
Code CN1 CN2 CN3 TOTAL
1. Extract the regional code from column ID, given that the second character displays the regional
code.
2. Calculate column Total: Total = CN1 + CN2 + CN3 + PA (With: PA is 1 if regional code is 1,
PA is 0,5 if regional code is 2, else PA is 0
3. Insert column “Scholarship type”. where:
- Type = A if Total >= 24 and no subject is less than 8
- Type = B if:
Total >= 24 and no subject is less than 6
Or Total >= 22 and no subject is less than 6 and PA is 1
- Others is Type C
4. Calculate scholarship based on scholarship type A, B, C
Scholarshi
Type
p
A 2000000
B 1000000
C 500000
5. Format table
Ex 2:
UNIT
FULL NAME ID QUANTITY
NAME
UNIT PRICE
SX QL
PX1 32000 32500
COEFFICIENT
Rank 1 2 3 4 5 6 7
- For short-term employees, apply a 10% tax rate and only apply if the income is 2 million or more.
Note: If Assessable income <=0, tax is 0
8) REAL INCOME = INCOME – ADVANCES
9) Combine ID and UNIT NAME to CODE
9) Use the function to get the current Month and Year
10) Present the salary calculation sheet for the production department.
Ex 3:
Requirement:
Create a column that inserts the number in the movie title at the end of the phrase The number in
the title of this movie is [number].
Movie Title
Ocean's 11
Blair Witch 3
District 9
13
Halloween 7
Scary Movie
12
Dodge Ball 8
Hint: use flashfill
Ex 5:
S/N: 156121, vib roller,Cummins dsl eng,OROPS Auction: 11/12/2004 in Pelham, New
Hampshire
Each row refers to a machine purchase. Determine the year of each purchase.
Ex 6:
In each row of below table, you will find a city’s zip code, city name, state (TX – Texas),
latitude, and longitude. Use formulas to extract the name of the city in each row. Assume that
each zip code is 5 characters long.