当前位置:网站首页>d不要直接用转串
d不要直接用转串
2022-08-04 12:35:00 【fqbqrr】
原文
不要直接用.toString,用std.format.format.
import std;
void main() {
auto x = BigInt("123123123123123123123123123123123123");
string s = format("%s", x); // 给你串表示
writeln(s); // 打印"123123123123123123123123123123123123"
// 转为dchar[]:
dstring ds = s.to!(dchar[]);
// 不用串,直接转为dchar[]
auto app = appender!(dchar[]);
app.formattedWrite("%s","x");
dchar[] dcharArray = app.data; //现在有d符.
}
边栏推荐
- The head module of the yolo series
- OAuth2图文快速入门
- 免费翻译软件哪个好用
- "Lonely Walking on the Moon" is a powerful medicine, it can't cure the internal friction of happy twist
- 开发小程序插件如何实现盈利?
- 干货丨数学规划视角下的分货优化解题思路
- 七夕疯狂搞钱的年轻人,一周赚14万
- “蔚来杯“2022牛客暑期多校训练营4 N
- du命令_set命令选项
- 5 cloud security management strategies enterprises should implement
猜你喜欢

RobotFramework二次开发(一)

MySQL必知必会(初级篇)

rpm安装提示error: XXX: not an rpm package (or package manifest):

他是“中台”之父,凭一个概念为阿里狂赚百亿

Programmer Qixi Gift - How to quickly build an exclusive chat room for your girlfriend in 30 minutes

干货丨数学规划视角下的分货优化解题思路

数据中台建设(九):数据中台资产运营机制

【UML】信息系统分析与设计知识点总结

TensorFlow学习记录(三):高阶操作 & 神经网络与全连接层

5 cloud security management strategies enterprises should implement
随机推荐
获取本机IP地址的脚本
A comprehensive understanding of MOS tubes, an article is enough
【UML】信息系统分析与设计知识点总结
【PHP实现微信公众平台开发—基础篇】第1章 课程介绍
双目立体视觉笔记(三)三角测量、极线校正
双目立体视觉学习笔记(一)
Two years of independent development experience Programmers tell us the experience of making money (listen to the masters who really make money)
Programmer Qixi Gift - How to quickly build an exclusive chat room for your girlfriend in 30 minutes
Escape character is ‘^]’什么意思?怎么使用telnet
Control CD-ROM with VbScript
FHQ-Treap 简介
持续交付(三)Jenkinsfile语法使用介绍
oracle sql中根据条件判断是否插入数据
Focusing on data sources, data quality and model performance to build a credit profile of small and micro enterprises
缓存字符流
全面认识MOS管,一篇文章就够了
"Lonely Walking on the Moon" is a powerful medicine, it can't cure the internal friction of happy twist
Focus!2022 interview must brush 461 interview questions summary + interview + resume template
ReentrantLock 原理
【软考 系统架构设计师】软件架构设计② 软件架构风格