dart - How to remove a character from string and concatinate it in Dart | Flutter
问题描述
I have two variables
String firstInput = "1.1.5";
String secondInput = "1.1.6";
From this I want the output firstOutput = 115
secondOutput = 116
How to remove dots from the string and concatenate remains as one variable ?
解决方案
You can use the replaceAll method.
It would look like String out = firstInput.replaceAll(".","");
推荐阅读
- sql-server - 您可以在实时生产 Windows 服务器上运行 SQL Server Developer 版本吗?
- java - 在运行时设置 application.properties
- java - Android Http 请求 POST JSON
- git - 如何显示包含父母信息的所有提交列表?
- javascript - 窗口提交方法内的Javascript停止工作
- pandas - Pandas:组合具有不同值的行
- python - 从导入的脚本函数返回 for 循环中的变量
- google-api - YouTube 数据 API 不再从 search.list 返回活跃的直播流
- sql - 计算每个 ID 显示的特定值的数量
- javascript - 使用javascript将数组作为猫鼬模式中的值