Recursion Examples

Feb 28, 2014
During my college days, we simply refer to recursion as a method that calls itself. Here's a simple program. Our goal is to compute the factorial of positive integer N. A non-recursive definition would look like this: int val = 1; for(int x=1; x <= N; x++) { val = val * x; } But when we define a recursive method, it would be something like this: int factorial(int N) { if(N == 1) return 1; else return N * factorial(N-1); } Here...
Read more ...

How to Add Syntax Highlighter in Blogger

Feb 27, 2014
Follow these very simple steps on how to add syntax highlighter for your Blogger blog. Go to Dashboard > Template. Click on Edit HTML. Copy the following code before the </head> tag. <!-- Syntax Highlighter Additions START --> <link href="http://alexgorbatchev.com/pub/sh/current/styles/shCore.css" rel="stylesheet" type="text/css" /> <link href="http://alexgorbatchev.com/pub/sh/current/styles/shThemeDefault.css"...
Read more ...

Sample Post with Syntax Highlighter

Feb 27, 2014
This is just a sample post using syntax highlighter. Will discuss how to install the highlighter in a different post. /// <summary> /// Fetches number of scripts /// </summary> /// <param name="rowIndex">Row index where number of scripts would be placed</param> private void DisplayNoOfScripts(int rowIndex) { int totalScripts = 0; string filterScript = string.Format(@"{0} NOT LIKE NULL" , Admin_Script.script_name.ToString(),); ...
Read more ...

"There are no games." in PSP

Feb 26, 2014
Not sure if this glitch still occurs but please allow me to share. My PSP shows this message "There are no games." but I am pretty sure there are. This happened when I added the game Rock Band Unplugged. Well, it seems that installing this game deletes the GAME folder, but not the games. To fix this, follow the steps below: Create a new folder and name it "GAME". Place the "GAME" folder inside the "PSP" folder. Create a...
Read more ...