Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
プログラムの結果を有効数字20桁で印刷する必要がありますが、15桁以上(フォーマット長)を印刷する方法がわかりません。これを達成する方法はありますか?
printfCの場合と同様に、次の形式指定子を使用して次の構文に従うことにより、出力の形式を制御できます。
printf
> printf('%.20f\n', pi) 3.14159265358979311600