Can someone show me a simple tail-recursive function in C++?
Why is tail recursion better, if it even is?
What other kinds of recursion are there besides tail recursion?
I understand the basics of Rx. Where I'm struggling is how you would actually use this beyond academic examples? What are some common, simple real-world scenarios where Rx is a much better solution than what we have today in .NET?
Hi,
I'm using mvvm light to build a Silverlight application.
Is there a code snippet that shows how to access a view model's property or command from within another view model or user control's code behind?
I guess it's simple, but I somehow missed something.
Ueli
I'm looking for a package that will automatically detect the type of and extract an archive (zip, tar.gz, etc). In Perl, this is easy - in Python, I can't find any simple package/class to do it...
this must be such a simple problem but can someone tell me why this doesnt work:
visibilityString1 = @"the";
visibilityString2 = @"end";
visibilityString = (@"This is %@ %@", visibilityString1, visibilityString2);
Every time I try to combine strings this way, it will only return the second string so what I get is:
end
Say I have a simple object such as
class Something
{
public int SomeInt { get; set; }
}
I have read that using immutable objects are faster and a better means of using business objects? If this is so, should i strive to make all my objects as such:
class ImmutableSomething
{
public int SomeInt { get { return m_someInt; } }
private int m_someInt = 0;
public void ChangeSomeInt(int newValue)
{
m_someInt = newvalue;
}
}
What do you reckon?
Can anybody give a simple Deadlock sample code in c#.net ? And please tell the simplest way to find deadlock in your C#.net code sample.(May be the tool which will detect the dead lock in the given sample code.)
NOTE: I have VS 2008
I want to unit test a WPF application and one scenario is to check that data bindings are correct. The simple way to do that would be to create the form, force it to bind to data and then compare the values from the controls with the expected ones. Is there any way to do that?
Hi, I'm looking for an alternave to the parse_ini_file() function in php. I want a simple way to store config settings, but want the flexibility to store unlimited levels of multiple arrays, special characters, etc. Any ideas?
Hi all,
I'm just curious if there is a simple way to do this, something along these lines
javascript:
if(document.getElementById('button').clicked == true)
{
alert("button was clicked");
}
html:
<input id="button" type="submit" name="button" value="enter"/>
Thank You
Ruth
Hi There,
Continuing with my adventure to convert COBOL to a Ruby program, I have to convert a decimal digit to a comp-3/packed decimal format. Anyone know of a simple Ruby script or gem that does this?
Berns
Hi there,
Does anyone know of a good open source toolkit that allows level designer and graphic designer or someone with basic programming experience to create multiplayer online Role Playing Game ? The game can be a simple 2D interface in a 2d virtual world.
I know Microsoft have a starter kit something like the following :
http://creators.xna.com/en-US/starterkit/roleplayinggame
that allows developer to create RPG game running on XBox platform but i am looking more on multiplayer role playing game on the web platform where player can play directly with their browser.
regards
Andrew
Hi All,
I have had thoughts of trying to write a simple crawler that might crawl and produce a list of its findings for our NPO's websites and content.
Does anybody have any thoughts on how to do this? Where do you point the crawler to get started? How does it send back its findings and still keep crawling? How does it know what it finds, etc,etc.
Thanks!
-Jason
Hello,
I'm trying to make a very simple program run on my Nokia 5000.
On the Nokia website, there is a SDK (Series 40). I included this SDK in my IntelliJ project.
The problem is, when I try to run the helloWorld app on my phone, I get an error message.
(http://wiki.forum.nokia.com/index.php/Hello_World_in_Java_ME)
Can anyone help me out?
Thanks in advance!
what programming language/languages do they use to produce games lik Bioware's Dragon Age Origins and some other 3-d games like Call of Duty?
If I would like to do 3d-game programming, where do I start? Are there even simple tutorials for this? I would like to do 3-d game programming for PC games:)
I need to implement a simple application to send short notify messages on gsm phone display via a GSM modem.
I know that I can use the gsm USSD protocol to send messages instead of sms in order to speed up the delivery.
Where I can find a detailed reference on the available USSD messages?
Where I can find examples or sample applications?
All mobile operators supports the USSD protocol?
Lorenzo
SO, I am trying create a simple regex that matches the following string:
..."chrX:33267175-33267784 610bp TGATGTTTGGCGAGGAACTC GCAGAGTTTGAAGAGCTCGG\nTGATGTTTGGCGAGGAACTCtactattgttacacttaggaaaataatcta\natccaaaggctttgcatctgtacagaagagcgagtagatactgaaagaga\ntttgcagatccactgttttttaggcaggaagaatgctcgttaaatgcaaa\ncgctgctctggctcatgtgtttgctccgaggtataggttttgttcgactg\nacgtatcagatagtcagagtggttaccacaccgacgttgtagcagctgca\ntaataaatgactgaaagaatcatgttaggcatgcccacctaacctaactt\ngaatcatgcgaaaggggagctgttggaattcaaatagactttctggttcc\ncagcagtcggcagtaatagaatgctttcaggaagatgacagaatcaggag\naaagatgctgttttgcactatcttgatttgttacagcagccaacttattg\ngcatgatggagtgacaggaaaaacagctggcatggaaggtaggattatta\naagctattacatcattacaaatacaattagaagctggccatgacaaagca\ntatgtttgaacaagcagctgttggtagctggggtttgttgCCGAGCTCTT\nCAAACTCTGC\n"...
I have created the following regex: <PRE>[.|[\n]]*</PRE>' yet it won't match the string above. Does anyone have a solution to this conundrum and perhaps a reasoning as toward why this doesn't work.
I would like to know if there's exists some simple code to get to the page i know its ID , I would like to create small input (no matter where in templates)from where the people can easily get to the page if they know it's page ID . I have the girls portfolio in wordpress - portfolio=pages x jobs in clubs offers=posts , I would like the girls portfolios to be easily findable by ID(s) , if possible the same for the posts=jobs in clubs
The best solution little numeric input and send button
Hello
I'm creating a simple AIR app with resize-functionality. Of course i need to position a resize-arrow to the bottom-right corner. Here's my code:
stage.addEventListener(Event.RESIZE, handleResize);
function handleResize(e:Event):void{
resize_btn.y = stage.stageHeight-resize_btn.height;
}
This doesn't work, my button gets out of the window very quickly. How could I make this work?
Martti Laine
Hi, Can every body tell me by simple answer where & what i can create a batch process for ordinary operations such saving, changing file properties and so...
Hi There,
I just started developing a simple Android application while I'm still learning its platform.
I'm using Eclipse IDE with the ADT plugin 0.9.6 and I need to know if it's possible to view the activity stack that is associated with a Task.
Is there any way through the DDMS tool or through any other technique?
Thanks in advance for your help/advice.
Mic
Is there a way to get pattern matching to match my value with any negative number? It does not matter what the negative number is I just need to match with any negative.
I have accomplished what I want with this simple code:
let y = if(n < 0) then 0 else n in
match y with
0 -> []
| _ -> [x] @ clone x (n - 1)
But I want to eliminate that if statement and just get it to check it as another case in the match statement
What is Service Broker in SQL Server and is it meaningful to enableitin a simple Database, Not in a distributed DB.
please do not close this question, I saw others similar question and non of them answered me.
Is there a simple way to convert a System.Drawing.Pen into its unmanaged counterpart? Like, if you had a Pen like this:
Pen p = new Pen(Color.Blue, 1f);
IntPtr ptr = p.ToPtr();
I know this code doesn't work, but is there a way to do it similarly?
The dialog box for adding a web form to a web project in Visual Studio has a checkbox to 'Select Master Page'. This checkbox doesn't exist in the Web Developer Express Edition. Is there a simple alternative to attach a Master Page while adding a new web form in the Express Version?