Posts
 
Reputation
Joined
Last Seen
Ranked #3K
Strength to Increase Rep
+0
Strength to Decrease Rep
-0
50% Quality Score
Upvotes Received
1
Posts with Upvotes
1
Upvoting Members
1
Downvotes Received
1
Posts with Downvotes
1
Downvoting Members
1
1 Commented Post
0 Endorsements
Ranked #2K
~2K People Reached
Favorite Forums
Favorite Tags

8 Posted Topics

Member Avatar for hughesadam_87

you can also make your own custom dict. custom type are done with classes class custom_dict(dict): # mydict[key] def __getitem__(self,key): return self.__dict__[key] # mydict[key] = value def __setitem__(self,key,value): if len(value) != 3: raise TypeError("Wrong numbers of arguments") elif isinstance(value[0],int) is False: raise TypeError("First argument not an integer") elif isinstance(value[1],int) is …

Member Avatar for hughesadam_87
0
440
Member Avatar for lawltman

This code you must keep hitting the down arrow key to change images [CODE]import pygame pygame.init() GREEN = (0,255,0) def main(): Screen = pygame.display.set_mode((400,400)) # pygame framerate control clock = pygame.time.Clock() # converting images is changing pixel layout. # it also lets transparent work # it speed up the drawing …

Member Avatar for DrakeMagi
0
245
Member Avatar for DrakeMagi

been googling for 5 days. The library has the book check out for the next 16 days. I'm using debian lenny linux , have nasm installed . I'm looking 1:1 assembly programing. No high level. to me no point in learning assembly if you going to use high level commands. …

Member Avatar for gerard4143
0
182
Member Avatar for persianprez

[CODE]if major = cmsc:[/CODE] should be [CODE]if major == cmsc:[/CODE] [QUOTE]I'm very confused, there must be an easier way to do this than using a million if statements. [/QUOTE] one solution [CODE]if coursenum in [201,202, 203, 304, 313, 331, 341, 345, 421] print '202, 203, 304, 313, 331, 341, 345, …

Member Avatar for d5e5
-1
135
Member Avatar for DrakeMagi

What am i doing wrong. Tadd.h [CODE]#ifndef ADD_H_GUARD #define ADD_H_GUARD int add(int a, int b); #endif[/CODE] Tadd.cpp [CODE]int add(int a, int b) { return a+ b; } [/CODE] Taddmain.cpp [CODE]#include <iostream> #include "Tadd.h" using namespace std; int triple(int x) { return add(x, add(x,x)); } int main() { int xi; xi …

Member Avatar for rajeevns
1
106
Member Avatar for DrakeMagi

Just want to create a flexible desktop that is independent from system. For my linux system. Like to have Clean Window and Transparent. 1. Looking for the basic on Xlib. Most of what i found is unclear where i start. I like to start simple and expand. a. Want to …

Member Avatar for DrakeMagi
0
441
Member Avatar for sravan953

this might help . [code=python]def reduces(s): x=int(s) p= 10 while p>9: p = 0 for i in str(s): p+= int(i) s = p return (p,x) s=raw_input("Enter a number: ") p , x = reduces(s) print(p)[/code]

Member Avatar for bumsfeld
0
131
Member Avatar for DrakeMagi

1. Opinions how to make it look better ? 2. How to make path for Linux ? using user ? 3. For Linux . What the difference between ( #! = user/bin/python , #! = user/bin/env python) ? 4. Anything i forgot or should consider ? [code=python] # ----- ----- …

Member Avatar for DrakeMagi
0
116

The End.