記事の内容
Dartで「null operators」である「??」を使う方法を紹介します。
このようなエラーが出た時に対応できます。
The argument type 'int?' can't be assigned to the parameter type 'num'.
null operators(??)
Mapのあるkeyにある値だけを合計する処理をしていますが、このコードではエラーが出ます。
null operatorsを使うことで、問題を解決しています。
プログラミング、フリーダイビング、ブロックチェーンのブログ
更新日:
記事の内容
Mapのあるkeyにある値だけを合計する処理をしていますが、このコードではエラーが出ます。
null operatorsを使うことで、問題を解決しています。
Copyright© プログラミング道場 , 2025 All Rights Reserved Powered by AFFINGER4.