Creating Schemas using the System.Xml.Schema Namespace:

Schema Output:

Code: