summaryrefslogtreecommitdiffhomepage
path: root/csharp.html.markdown
diff options
context:
space:
mode:
authorMelvyn <melvyn.laily@gmail.com>2013-09-21 15:39:59 -0400
committerMelvyn <melvyn.laily@gmail.com>2013-09-21 15:39:59 -0400
commit67b9af44925a66ac0dc278050bcaaa80fd50f21c (patch)
tree63a3760c7191ece740585d35df33d0652059683e /csharp.html.markdown
parent41cf74fa53b1d315e2909e1ea62f4874727b578a (diff)
added details for the switch statement for C#
Diffstat (limited to 'csharp.html.markdown')
-rw-r--r--csharp.html.markdown8
1 files changed, 8 insertions, 0 deletions
diff --git a/csharp.html.markdown b/csharp.html.markdown
index 7239ca52..dcbb30d1 100644
--- a/csharp.html.markdown
+++ b/csharp.html.markdown
@@ -343,6 +343,14 @@ namespace Learning
case 3:
monthString = "March";
break;
+ // You can assign more than one case to an action
+ // But you can't add an action without a break before another case
+ // (if you want to do this, you would have to explicitly add a goto case x
+ case 6:
+ case 7:
+ case 8:
+ monthString = "Summer time!!";
+ break;
default:
monthString = "Some other month";
break;