How is a computer programmed to play chess? How is a computer programmed to play chess? What are the ways by which they sort out the moves? My question is not about programming but the idea behind programming to play chess. That can really help me in chess.
Chess programming is full of "rules of thumb" that can be applied to your own chess.  There are many aspects to chess programming... but the most prominent are tree search and a heuristic evaluation.  Here are some ideas that you might be able to apply to your games:


Minimax Search: The basis for adversarial search formalized... I'd hope the principle here was intuitive.
Evaluation: A computer scores a position by combining metrics about material balance, king safety, activity, and pawn structure.  This goes into a strategic understanding of any given position.
Iterative Deepening: The applicable idea here might be to consider your list of candidates first, prior to expending to a deeper level of analysis.
Killer Moves: An amazing move discovered in one line of your analysis might be applicable in other lines of analysis... consider it early in the process.
Null Move Pruning: You can better understand your opponents intentions by considering what moves they would make if you were to skip your own turn.
Quiescence Search: When you reach the end of some analysis, make sure everything is still ok if you were to resolve the tension in the position.
MVV-LVA: This one is obvious, but in considering capture patterns, usually a good idea to identify the most valuable victim, and take with the least valuable attacker.
Alpha Beta Search: You can stop considering a line when you find the first refutation to it, rather than continuing to search for a better refutation.