using System;
using System.IO;
using System.Xml;
public class Sample {
public static void Main() {
XmlDocument doc = new XmlDocument();
doc.LoadXml("" +
"C# " +
" ");
XmlNode root = doc.FirstChild;
string ns = root.GetNamespaceOfPrefix("bk");
XmlNode attr = doc.CreateNode(XmlNodeType.Attribute, "genre", ns);
attr.Value = "novel";
root.Attributes.SetNamedItem(attr);
doc.Save(Console.Out);
}
}