a. Hierarchical access is mentioned in question.
$T_{avg}= time_{cache}+ \left(1-hit_{cache}\right)\left[time_{memory}\right]$
$=2.5+(1-.95)[125]$
as line size is 64 bytes there are 16 words in a cache line fetch and first word is of four bytes having access time 50 ns and remaining fifteen have access time 75 ns(i.e.,125 ns )
$=2.5 + 6.25$
$=8.75$
(b)
now line size increases ie 128 bytes as now there are 32 words .
first word access is 50 ns than after that 5 for each 31 words
$=50+155$
$=205$(block access time)
now hit ratio is .97
$T_{avg}=2.5+(1-.97)[205]$
$=2.5 + 6.15$
$=8.65$