D (The Programming Language)/d2/Lessons Style Guide

Lesson T: A Style Guide edit

In this template-like guide, you see the general layout for these phobos/language lesson pages.

Introductory Code edit

Code Example 1 Title edit

You may write a description of the code sample.

import std.stdio;

void main()
{
    writeln("Thank you for your contributions to this book.");
}

Code Example 2 Title edit

Code examples are for introducing the concepts of the lesson to the reader. They do not necessarily have to show every concept. It's even nicer if the code example did something useful and/or interesting.

import std.stdio;

void main()
{
    writeln("Soon these lessons will be complete.");
}

Concepts edit

Concept 1 edit

The navbar at the top is a template. You can look at the source code of this page to see how it is used. The 0 and the T lessons are there on the navbar temporarily until the lessons get better (when these lessons can actually be used for learning).

writeln("Wikimarkup can get so messy");
writeln("When you make complex templates");
writeln("D's templates are bliss compared to them");

Concept 2 edit

Concepts are generally very important and crucial pieces of information about D. It is okay to assume that the reader has solid knowledge of C or C++ when writing these concepts.

Conclusion edit

Lessons can optionally have a conclusion. Often, the conclusion is used to inform the reader about what direction the next lessons go in and how it all ties together.

Tips edit

  • Tips are information that aren't quite important enough to put inside of the concepts section. Do not use <syntaxhighlight> or <syntaxhighlight> tags here.
  • Tip 1
  • Tip 2
  • Thank you for reading.