Table:
0
A
B
C
D
E
F
1
#
Episode
Director
Writer
Original airdate
Viewers
2
1
"Episode 1"
Martin Hutchings
Tony Jordan
8May2007
5.46m
3
2
"Episode 2"
Martin Hutchings
Tony Jordan
15May2007
5.16m
4
3
"Episode 3"
Bryn Higgins
James Payne
22May2007
4.42m
5
4
"Episode 4"
Bryn Higgins
Sarah Phelps
29May2007
N/A
6
5
"Episode 5"
Barnaby Southcombe
Jeff Povey
5June2007
4.1m
7
6
"Episode 6"
Barnaby Southcombe
Richard Davidson
12June2007
4m
8
7
"Episode 7"
Martin Hutchings
Marc Pye
19June2007
4.13m

Questions and formulas:
Question:  who is the writer where viewers is 5.16m
Formula: UNIQUE(CHOOSECOLS(FILTER(A1:F1,F1="5.16m"),4))
Formula2: UNIQUE(CHOOSECOLS(FILTER(A2:F8,F2:F8="5.16m"),4))
Level: medium
Question:  who is the writer for episode "episode 7"
Formula: UNIQUE(CHOOSECOLS(FILTER(A1:F1,B1="Episode 7"),4))
Formula2: UNIQUE(CHOOSECOLS(FILTER(A2:F8,B2:B8="Episode 7"),4))
Level: medium