Just a little fun with Python's named tuple, behaves like a class but is much leaner.

Member Avatar
Member Avatar
+2 forum 6

One solitaire game practice until the first win or 'q' after game.

Member Avatar
+0 forum 0

I have left my source of information as docstring comment on code side. If you want to solve the problem yourself do not run the code. This code actually gives the correct answer. I have not reacted to the border case comment in my formula source as it is quite common to consider on border part of inside. You can add the simple check with optional parameter for how to react to case, for example, if you need it. As everybody have read carefully Python documentation, the source of Point object by namedtuple should be clear. It is worth to …

Member Avatar
+0 forum 0

The code from my answer to thread: [url]http://www.daniweb.com/forums/thread292949.html[/url] Any field names with any same separator separating the values. This is straight text file reading routine, see the original thread for csv module based code. sample.dat: [CODE]id; name; email; homeaddress 123; gishi; gishi@mymail.com; 456 happy st. 345; tony; tony.veijalainen@somewhere.com; Espoo Finland [/CODE]

Member Avatar
Member Avatar
+0 forum 1

The End.