title: How To Display Variable Value In View?
body: <p>Here I am trying to display variable <code>y</code> value in <code>td</code> in view(i.e .cshtml).
  But have no idea how to do that.</p>
  
  <p>Below is my view:</p>
  
  <pre><code>&lt;td&gt;
      @Html.DisplayFor(modelItem =&gt; item.District)
  &lt;/td&gt;
  &lt;td&gt;
      @{
          var y = v.GetContestantAverageRatingByContestantId(item.ContestantId);
      }
  &lt;/td&gt;
  </code></pre>