@foreach (string strCountry in ViewBag.Countries){
<li>
@strCountry
</li>
}
Try with this dear.
This will work out. As you are using loop that should have a start and close brackets.
Similar to server side code.
I hope this works.
Post back your queries if any.
Thanks.:)