Anonymous user
Regular expressions: Difference between revisions
m
→{{header|D}}: lang tag
m (→{{header|C++}}: ww nl; lang tag) |
m (→{{header|D}}: lang tag) |
||
Line 207:
=={{header|D}}==
<lang d> import std.stdio, std.regexp;
void main() {
Line 227:
auto re2 = RegExp(" a ");
writefln(re2.replace(s, " another "));
}</lang>
Note that in std.string there are string functions to perform those string operations in a faster way.
|