There are many methods of doing this. This one finds the median; however, instead of halving, you can use quarters instead.
First order the data, ascendingly:
10, 17, 18, 18, 18, 20, 20, 25, 25, 30, 30
Find the median:
For an even number of values: The number of values / 2
For an odd number of values: The number of values + 1 / 2
11 is odd.
11 + 1 / 2
12 / 2 = 6
The median is at the 6th position.
10, 17, 18, 18, 18, 20, 20, 25, 25, 30, 30
The median is 20.
Other method:
You don't need this step.
Using the values lower than the median, exclusive, find the median of the lower values;
For an odd number of values: The number of values + 1 / 2
10, 17, 18, 18, 18
5 + 1 / 2 = 6 / 2 = 3
The median of the lower values is at position 3.
This is the lower quartile.
10, 17, 18, 18, 18
Other method:
For an odd number of values: The number of values + 1 / 4
11 + 1 / 4 = 12 / 4 = 3
10, 17, 18, 18, 18, 20, 20, 25, 25, 30, 30
Using the values greater than the median, exclusive, find the median:
For an odd number of values: The number of values + 1 / 2
20, 25, 25, 30, 30
5 + 1 / 2 = 6 / 2 = 3
The median of the upper values is at position 3.
20, 25, 25, 30, 30
This is 25.
This is the upper quartile.
Other method:
For an odd number of values: (The number of values + 1 / 4) * 3
(11 + 1 / 4) * 3 = (12 / 4) * 3 = 3 * 3 = 9
10, 17, 18, 18, 18, 20, 20, 25, 25, 30, 30
Your interquartile range is 3 - 25
25 - 3 = 21
21