background preloader

A-star Shortest Path Algorithm & C++ recipes & ActiveState Code

A-star Shortest Path Algorithm & C++ recipes & ActiveState Code

Top 10 Ways to be Screwed by "C" To get on this list, a bug has to be able to cause at least half a day of futile head scratching, and has to be aggravated by the poor design of the "C" language. In the interests of equal time, and to see how the world has progressed in the 20-odd years since "C" escaped from its spawning ground, see my Top 10 Ways to be Screwed by the Java programming language, and for more general ways to waste a lot of time due to bad software, try my Adventures in Hell page. A better language would allow fallible programmers to be more productive. Non-terminated comment, "accidentally" terminated by some subsequent comment, with the code in between swallowed. a=b; /* this is a bug c=d; /* c=d will never happen */ Accidental assignment/Accidental Booleans if(a=b) c; /* a always equals b, but c will be executed if b! Closely related to this lack of rigor in booleans, consider this construction: if( 0 < a < 5) c; /* this "boolean" is always true! Or consider this: if( a =! Unhygienic macros or as Oops.

Game From Scratch | Game From Scratch C++ Edition! Want to create a game using C++ and SFML? This is the perfect place to start! This tutorial series will follow the creation of a simple game in C++ from the very beginning till the end, a micro-version of the overall purpose of this site. C++ is an evolving language standard and a great many tutorials out there are horrifically outdated or just plain bad. Similarly, most tutorials in books or on sites are by their very nature required to be very short and concise. This site fortunately does not have that restriction, so I can babble on and on and on… This series is meant to be a living document, so if you have any questions on specific section, let me know and I will update accordingly! Finally, I don’t pretend to be an expert on C++ nor SFML, so if you see a mistake or you disagree with something I have said, let me know. Alright, lets get this started. EDIT: This tutorial was written a couple years ago and targets Visual Studio 2010. The Introduction Part 1 Part 2 Part 3 Part 4 Part 5 Part 6

Conway's Game of Life "Conway game" redirects here. For Conway's surreal number game theory, see surreal number. The Game of Life, also known simply as Life, is a cellular automaton devised by the British mathematician John Horton Conway in 1970.[1] The "game" is a zero-player game, meaning that its evolution is determined by its initial state, requiring no further input. One interacts with the Game of Life by creating an initial configuration and observing how it evolves or, for advanced players, by creating patterns with particular properties. Rules[edit] The universe of the Game of Life is an infinite two-dimensional orthogonal grid of square cells, each of which is in one of two possible states, alive or dead. The initial pattern constitutes the seed of the system. Origins[edit] The game made Conway instantly famous, but it also opened up a whole new field of mathematical research, the field of cellular automata ... Conway chose his rules carefully, after considerable experimentation, to meet these criteria:

A Quick, Painless Tutorial on the Python Language Norman Matloff University of California, Davis June 17, 2008 ©2003-2008, N. Contents What Are Scripting Languages? Languages like C and C++ allow a programmer to write code at a very detailed level which has good execution speed (especially in the case of C). The term scripting language has never been formally defined, but here are the typical characteristics: Used often for system administration, Web programming, text processing, etc. Why Python? The first really popular scripting language was Perl. Advocates of Python, often called pythonistas, say that Python is so clear and so enjoyable to write in that one should use Python for all of one's programming work, not just for scripting work. Background Needed Anyone with even a bit of programming experience should find the material through Section 8 to be quite accessible. The material beginning with Section 10 will feel quite comfortable to anyone with background in an object-oriented programming (OOP) language such as C++ or Java. Approach

Script Junkie | Building Cross-Platform Apps Using jQuery Mobile jQuery Mobile introduces a cross-platform and cross-device framework for developing mobile applications. It supports a wide variety of mobile browsers and delivers a unified user interface to the devices. It has simplified working with mobile browsers by abstracting away inconsistences between the vendors. Just as jQuery changed the way we wrote JavaScript , jQuery Mobile will change the way we build mobile web applications. I recently used jQuery Mobile to build an application and was stunned at how smoothly the development process went. As a web developer, jQuery Mobile is instantly rewarding because there isn’t much of a learning curve. Page Structure and Components We are going to build a to-do application. For this application there is only going to be one physical page, index.html. Aside from referencing the latest version of jQuery, we also reference jquery.mobile-1.0a4.1.min.css and jquery.mobile-1.0a4.1.min.js via CDN. Let’s fill out our create page. Conclusion About the Author

Publications by Googlers Google publishes hundreds of research papers each year. Publishing is important to us; it enables us to collaborate and share ideas with, as well as learn from, the broader scientific community. Submissions are often made stronger by the fact that ideas have been tested through real product implementation by the time of publication. We believe the formal structures of publishing today are changing - in computer science especially, there are multiple ways of disseminating information. We encourage publication both in conventional scientific venues, and through other venues such as industry forums, standards bodies, and open source software and product feature releases. Open Source We understand the value of a collaborative ecosystem and love open-source software. Product and Feature Launches With every launch, we're publishing progress and pushing functionality. Industry Standards Our researchers are often helping to define not just today's products but also tomorrow's. Resources Impact

Java Tutorial 7 - String Manipulation String manipulation forms the basis of many algorithms and utilities such as text analysis, input validation, and file conversion. This tutorial explores some of the needed basics. Unless otherwise noted, the following classes are contained in the java.lang library. NOTE: For the following parameters the prefix g indicates string, i indicates integer and c indicates character types. The String Class String class objects work with complete strings instead of treating them as character arrays as some languages do. Accessor methods: length(), charAt(i), getBytes(), getChars(istart,iend,gtarget[],itargstart), split(string,delim), toCharArray(), valueOf(g,iradix), substring(iStart [,iEndIndex)]) [returns up to but not including iEndIndex] Modifier methods: concat(g), replace(cWhich, cReplacement), toLowerCase(), toUpperCase(), trim().Note: The method format(gSyn,g) uses c-like printf syntax for fixed fields if required in reports. String class objects are immutable (ie. read only). Projects

YouTube Playlists for Learning Programming YouTube has been very good platform for learning any thing. Earlier you have seen 400+ courses on YouTube and 130+ NPTEL courses. There are few more courses especially about computer programming. These are contributed by various individuals. These videos are of short time around 10 to 12 min each, created keeping basic learners in the mind. thenewboston: thenewboston is a great youtube channel, has more than 2o playlists covering topics Python, C, Java, iPhone development and web programming like HTML, CSS, PHP. Xoax.net Xoax has more than 200 videos but mainly focuses on C++. PHPacademy As the name suggests, it focuses mainly on PHP and some on MySql. There are more videos on small projects like writing your own search engine for your database, pagination, creating a rating system etc… Related posts: Get more stuff like this

CoRR - Computing Research Repository Welcome to the Computing Research Repository Welcome to the Computing Research Repository (CoRR). CoRR allows researchers to search, browse and download papers through its online repository. CoRR is available to all members of of the community at no charge. Please feel free to explore the site and features. Help links and general information about CoRR are provided on the left panel, and key features (Advanced Search/Browse, Submit, Subscribe, Preferences) are above. First time user? View Listings Computing Research Repository (CoRR): new, recent, abs, find By Category:

Syrie : Ultrasurf, ou comment le gouvernement Syrien piège ses opposants avec un malware Après l’Égypte ce matin, notre équipe s’est attaquée à la problématique syrienne. Nous avons cherché à comprendre comment le pouvoir de Bachar el Assad s’y prenait pour voler les comptes Facebook, Twitter, ou Gmail de ses opposants, et comment il parvient à les identifier pour les arrêter. Nous avons réussi à mettre en lumière l’un des procédés du gouvernement Syrien afin de piéger ses opposants. C’est l’histoire banale d’un logiciel qui fait le contraire de ce qu’il prétend faire. Ultrasurf est un logiciel proxy qui a été très utilisé par les dissidents syriens. Mais voilà, la version qui a été largement diffusée en Syrie contenait un petit paquet cadeau. Vous trouverez également le dump pcap de l’activité réseau de ce logiciel ici (à ouvrir avec Wireshark). Le comportement semble relativement élaboré : redirection du 80 vers le ssl, encapsulation des données dans un tunnel et surtout, une modification en base de registre de tous les certificats SSL. Greets halona, fo0 & Julie

How to recognise a good programmer It’s not as easy as it sounds. CV experience is only of limited use here, because great programmers don’t always have the “official” experience to demonstrate that they’re great. In fact, a lot of that CV experience can be misleading. I consider myself to be a pretty good programmer. In his article The 18 mistakes that kill startups , Paul Graham makes the following point: “… what killed most of the startups in the e-commerce business back in the 90s, it was bad programmers. In practice what happens is that the business guys choose people they think are good programmers (it says here on his resume that he’s a Microsoft Certified Developer) but who aren’t. So how do you pick good programmers if you’re not a programmer? I disagree with Mr Graham on this one. #1 : Passion In my corporate experience, I met a kind of technical guy I’d never met before: the career programmer. I believe that good developers are always passionate about programming. #2 : Self-teaching and love of learning

21 Laws of Computer Programming Jun 17 As any experienced computer programmer knows, there are unwritten laws that govern software development. However there are no penalties for breaking these laws; rather, there is often a reward. Following are 21 Laws of Computer Programming:

Related: