Wednesday, September 21, 2011

Music 'n' Coding C#

Its a very long time but am back to share some of my learnings/things that i like with my blog~~~~~ again. This time i came up with some of the codings that i worked for my pleasure.  I have joined guitar class in my local area few weeks back and last week my master taught me thaattu varisaigal (meaning jumping notes), well its tough to practice but it is a very important basic lesson as he told.

I loved the arrangements of this notes so thought to write a code then, so here is the code.

Logic is : Print 1st character jump two chars, then print 4th and print back from it, now print the striaght ones, for example  C, D, E, F is straight and jumped one is C, F, E, D. You can find the output in the end of the code.



private static void generateJumpingNotesEasily()
{
string[] notes = new string[] { "C", "D", "E", "F", "G", "A", "B", "~C" };
//string[] notes = new string[] { "Sa", "Re", "Ga", "Ma", "Pa", "Tha", "Ne", "~Sa" };
StringBuilder jumpingResultNotes = new StringBuilder();
StringBuilder reverseJumpingResultNotes = new StringBuilder();
Console.WriteLine("Jumping Notes aka Thaattu Varisaigal");
Console.WriteLine("------------------------------------");
Console.WriteLine();

for (int j = 0; j <= notes.Length - 1; j++)
{
Console.Write(notes[j]);
Console.Write(" ");
}
Console.WriteLine();
Console.WriteLine("-----------------------------------");
for (int i = 0; i <= 4; i++)
{
jumpingResultNotes.Append(notes[i]);
jumpingResultNotes.Append(notes[i + 3]);
jumpingResultNotes.Append(notes[i + 2]);
jumpingResultNotes.Append(notes[i + 1]);
jumpingResultNotes.Append(" | ");
jumpingResultNotes.Append(notes[i]);
jumpingResultNotes.Append(notes[i + 1]);
jumpingResultNotes.Append(notes[i + 2]);
jumpingResultNotes.Append(notes[i + 3]);
jumpingResultNotes.Append(" | ");
}

Console.WriteLine(jumpingResultNotes);
Console.WriteLine();

//this is from the end of the string array (reverse )
for (int k = notes.Length - 1; k >= 3; k--)
{
reverseJumpingResultNotes.Append(notes[k]);
reverseJumpingResultNotes.Append(notes[k - 3]);
reverseJumpingResultNotes.Append(notes[k - 2]);
reverseJumpingResultNotes.Append(notes[k - 1]);
reverseJumpingResultNotes.Append(" | ");
reverseJumpingResultNotes.Append(notes[k]);
reverseJumpingResultNotes.Append(notes[k - 1]);
reverseJumpingResultNotes.Append(notes[k - 2]);
reverseJumpingResultNotes.Append(notes[k - 3]);
reverseJumpingResultNotes.Append(" | ");
}
Console.WriteLine(reverseJumpingResultNotes);
Console.WriteLine();
}
}
}
Output
Jumping Notes aka Thaattu Varisaigal
------------------------------------

Sa Re Ga Ma Pa Tha Ne ~Sa
-----------------------------------
SaMaGaRe | SaReGaMa | RePaMaGa | ReGaMaPa | GaThaPaMa | GaMaPaTha | MaNeThaPa |
MaPaThaNe | Pa~SaNeTha | PaThaNe~Sa |

~SaPaThaNe | ~SaNeThaPa | NeMaPaTha | NeThaPaMa | ThaGaMaPa | ThaPaMaGa | PaReGa
Ma | PaMaGaRe | MaSaReGa | MaGaReSa |



If input is C D E F G A B ~C
-----------------------------------
CFED | CDEF | DGFE | DEFG | EAGF | EFGA | FBAG | FGAB | G~CBA | GAB~C |

~CGAB | ~CBAG | BFGA | BAGF | AEFG | AGFE | GDEF | GFED | FCDE | FEDC |

I think this can be used in some encryption algorithms with some more tweaks.

Next time i will share something more interesting which is also generous. Happy MusiCoding

Tuesday, February 9, 2010

This time the Great (Surface Gaming) Project DnD

How so funny game is becoming so fascinating, jaw-dropping game. This is not even came from a commercial gaming development company but from the intelligent students from Carnegie Mellon University. Come cheer up guys this is a great game developed by using our great language C#.NET, XNA and Visual Studio 2008, based on Microsoft surface technology and it is called as Dungeons & Dragon’s shortly D&D. Keep it up (CMU) guys. Cheers!.
 
Dont forget to look at this videos,


SurfaceScapes Gameplay Session from Surfacescapes on Vimeo.

Promotional Video...


SurfaceScapes Promo Video from Surfacescapes on Vimeo.


Now its worthwhile to look at their interview.....

http://blogs.msdn.com/surface/archive/2009/12/16/new-gameplay-video-with-d-d-on-surface.aspx

http://blogs.msdn.com/surface/archive/2009/12/08/bringing-d-d-to-microsoft-surface.aspx



 

Wednesday, December 16, 2009

Quickies - Pranav's previous innovation

This project is also very cool. Just check out the video here. Sticky notes written will send SMS, email, stored in your system. Enable searching to keep you where you had put your book and so many cool real life features. For more info read the link here http://www.pranavmistry.com/projects/quickies/


Monday, December 7, 2009

Pranav Mistry(Sixth Sense) - The most inspiring Indian

After a long time, accidentally i saw the www.ted.com website , i found this title there,  Sixth Sense. Its creating more magic in my mind and thats what the TED website mantra also. The Sixth Sense demo by Pattie Maes is awesome, amazing, ingenious and as an indian made me very proudable. After that, each and every day am seeing this video and I lost my sleep at that day, after two weeks, came to knew that its not only me, but also all the people who saw this demo has been went through the same different experience. 

Again at November 2009 Pranav Mistry gave the demo but this time he took us to different altitude than before.  

One more thing that I need to tell you definitely, after the demo, pranav said that he don't want his project to live or stay in the Lab, instead he wants people to use it, so he gives the software as free open source. What a man he is?   

If he sell his software, he will be another Bill Gates, this is not the point that i said, but also some of the media.(Anantha Vikatan on 2 Dec 2009- Tamil Magazine(India))


OK let us see the videos now here and you could also download it from www.TED.com

See this first demo of Sixth Sense by Pattie and then our Intelligent Bravo Pranav Mistry.

Pattie Maes and Pranav Mistry demo SixthSense

(Recorded in February 2009 in Long Beach, California. )



Pranav Mistry: The thrilling potential of SixthSense technology

(Recorded in November 2009 at Infosys Campus, Mysore, India)

Wednesday, January 2, 2008

My Technical Blogs List

I always used to read blogs because its were i learned new things beyond my current project. In my list there is so many technocal experts like Omar Al Zabir, Mark Russinovich etc. By reading Omar Al Zabir blogs(co-founder of PageFlakes and young MVP )was inspired me lot to do more in .NET. He taught many concepts to his readers thats include Silverlight, AJAX etc. Personally i learned more things from him. Please have a look at his blog.

http://msmvps.com/blogs/omar/

Monday, December 24, 2007

.NET R&D

Hi guys,

I am very new to the blog writing itself even though i had read several technical blogs. Here i am going to share the things that i have been learned. Hope you and me enjoy a lot with this blog and I request you to share the same thing with me.


With reagrds ,
DeviMurugan