Click here to Skip to main content
Click here to Skip to main content

Tagged as

Console pseudo Artificial Intelligence

, 26 Nov 2009 CPOL
Rate this:
Please Sign up or sign in to vote.
Console application that assumes artificial inteligence to the feable user


Presenting a way to "fake" Artificial Intelligence (AI), leading the user to assume that the application is responding to their every command.  


In Newton's 3rd Law of Motion, it states that every action has an equal and opposite reaction. We can apply this theory within our application by saying that every input will provide us with an output formed according to the input. This is call AI. 

Using the code 

Here we can see how some of the internal AI logic is structured:  

Console.WriteLine("What is your name?");
string name = Console.ReadLine();
Console.WriteLine("Hello " + name + ", how are you?");


The Console class which comes from the System namespace is used in this instance. The class exposes very useful methods which we can use to create our AI application, namely the WriteLine(string value) and the ReadLine() methods. The write line in our context, presents text through the console and gives the user the impression that the console is interacting with them. When the user types a reply to a question suggested by the console, the console already anticipates the answer and when an answer is given, it is taken and output to the user. This is where the input -> output scenario comes into play. 

The term "pseudo" is intelligently used to describe the application's AI. This is to not mislead the developers in assuming that the use of complex and absolute AI is used, but rather to show that it is simply producing output according to predefined actions  

Points of Interest

It is interesting to note how scientific concepts have so much relevance, even within a computing environment or context. 


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Self employed
United States United States
Coding and Mathematics is my life, without it I do not know what I would be.

Comments and Discussions

GeneralMy vote of 1 PinmemberFRANCISCO NEVES4-Nov-12 14:40 
GeneralThis is a joke, right? PinmemberProgramm3r13-May-12 23:19 
GeneralMy vote of 1 PinmemberDreamSoft.ps9-May-12 14:54 
GeneralMy vote of 1 Pinmemberkamiccolo29-Dec-09 0:20 
GeneralMy vote of 1 PinmemberT-Gadfly12-Dec-09 7:02 
GeneralMy vote of 1 PinmemberDan Neely30-Nov-09 3:19 
GeneralMy vote of 1 PinmemberThe Cake of Deceit29-Nov-09 10:23 
GeneralI love this! PinmvpHans Dietrich28-Nov-09 11:43 
GeneralMy vote of 1 PinmemberJouketje27-Nov-09 6:56 
GeneralMy vote of 1 PinmemberRichard MacCutchan27-Nov-09 6:49 
GeneralMy vote of 1 PinmemberMichael B. Hansen27-Nov-09 0:54 
GeneralTo be; or not to be..... PinmemberProgramm3r26-Nov-09 20:21 
GeneralMisunderstood PinmemberJohn Spectacle26-Nov-09 20:05 
GeneralMy vote of 1 PinmemberBartosz Wojcik26-Nov-09 15:38 
GeneralMy vote of 1 Pinmembersplendiderwer26-Nov-09 13:26 
GeneralMy vote of 1 PinmemberNicholasSimmons26-Nov-09 10:06 
GeneralYou forgot something... PinmemberNicholasSimmons26-Nov-09 10:05 
GeneralMy vote of 1 PinmemberGünther M. FOIDL26-Nov-09 9:39 
GeneralMy vote of 1 PinmemberUroš Šmon26-Nov-09 8:31 
GeneralMy vote of 1 Pinmembersam.hill26-Nov-09 7:34 
GeneralMy vote of 1 PinmemberRedFraggle26-Nov-09 6:50 
GeneralMy vote of 1 Pinmemberjharrison26-Nov-09 6:41 
GeneralMy vote of 1 PinmemberWilliam John Adam Trindade26-Nov-09 5:51 
GeneralMy vote of 1 PinmemberSeishin#26-Nov-09 5:09 
GeneralMy vote of 1 PinmemberArmando Airo'26-Nov-09 4:54 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Terms of Use | Mobile
Web04 | 2.8.150224.1 | Last Updated 26 Nov 2009
Article Copyright 2009 by prof3ssor
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid