← dlang

exforloop2.d

a66bdf67fae76e8f95a066847d224ea7188ac807 · ovidiucs · Sep 7, 2015 10:52

+3 −3 · 1 file changed

  • exforloop2.d +3 −3
diff --git a/exforloop2.d b/exforloop2.d
index 5cae1d4..2ad144a 100644
--- a/exforloop2.d
+++ b/exforloop2.d
@@ -21,11 +21,11 @@ void main()
          q = q ~'*';
       }
    }
-   q[] = 'x';
+   char s[];
    for (int z = 0; z < i; ++z)
    {
-      q = q ~' ';
-      writeln(q);
+      s = s ~' ';
+      writeln(s);
       for (int x = 0; x < i; ++x) 
       {
          write("*");