>>14
簡単な計算はWolframでやってみる。
なにかと{}がついてお世話な出力になる。

Wolfram Language 14.0.0 Engine for Microsoft Windows (64-bit)
Copyright 1988-2023 Wolfram Research, Inc.

In[1]:= Solve[x^2==5^2+8^2-2*5*8*Cos[Pi/3] && x>0,x]

Out[1]= {{x -> 7}}

In[2]:=
In[2]:= x /.Solve[x^2==5^2+8^2-2*5*8*Cos[Pi/3] && x>0,x]

Out[2]= {7}

In[3]:=
In[3]:= x /. Solve[x^2==5^2+8^2-2*5*8*Cos[Pi/3] && x>0,x][[1]]

Out[3]= 7