I start with c# syntax to get month name from month number,
System.Globalization.DateTimeFormatInfo mfi = new
System.Globalization.DateTimeFormatInfo();
string strMonthName = mfi.GetMonthName(8);
and for abbrevated month name i use
string strMonthName = mfi.GetAbbreviatedMonthNa...
The basics:
Consider the following tetrominoes and empty playing field:
0123456789
I O Z T L S J [ ]
[ ]
# ## ## ### # ## # [ ]
# ## ## # # ## # ...
Hi All,
I wanted to ask,
If writing nested(deep) iteration loops (as shown in example) a bad practice (in OOPs)?
For example :
If i want to zip all files that in all Workspaces.
Given example classes are Workspace, Project , File
please ignore avoid syntax errors
for each Workspace workspace in WorkSpaces
{
Pro...
The Challenge
The shortest code by character count that will output the Morris Number Sequence. The Morris Number Sequence, also known as the Look-and-say sequence is a sequence of numbers that starts as follows:
1, 11, 21, 1211, 111221, 312211, ...
You can generate the sequence infinitely (i.e, you don't have to generate a specific n...
Let's give the GMO guys something to cry about:
Goal: Generate a sequence of DNA base pairs (A, T, G or C), 78 pairs long (not a big gene...), terminated by a newline, and print it.
Rules: The lines must be exactly 78 characters long with a terminating newline, and while the program can give the same result if invoked twice in a row, i...