- Strength to Increase Rep
- +0
- Strength to Decrease Rep
- -0
- Upvotes Received
- 2
- Posts with Upvotes
- 2
- Upvoting Members
- 2
- Downvotes Received
- 1
- Posts with Downvotes
- 1
- Downvoting Members
- 1
Re:
There seems to be many ways to create a dictionary, which one do you prefer? |
|
Pretty self explanatory code. Why doesn't it work! #include <stdio.h> int main() { __asm__("number dw 0"); // declare number? printf("%d",number); __asm__("mov %eax,number" "inc %eax" "mov number,%eax"); printf("%d",number); return 0; } cc ex1.c -o ex1 ex1.c: In function ‘main’: ex1.c:22:17: error: ‘number’ undeclared (first use in this function) ex1.c:22:17: note: each … |
|
Re:
Recently I have been learning about the socket module and how you can create networking applications using it. I was curious if it would be possible using the socket module to either: Set the port as a USB port to trick the computer into thinking a USB is plugged in … |
|
Re:
I am currently working on my first serious GUI application in python using Tkinter. I currently have a toplevel window that opens from the root window. when i envoke the window from the root i can see all 7 of my other widgets, but the widget: btncancel = Tkinter.Button(addboard, text … |
|
Re:
hi, i'm new to python. i want to read from a text file (as attached) and i want to plot a scatterplot. i want to plot lane as X-axis, EyVt and EyHt as Y-axis. i have a sample code but i need help on how to get python start reading … |
|
Re:
hi all........ file1 99 root S 5176 95 [B]41.2[/B] 8.3 snmpd file2 99 root S 5176 95 [B]1.0 [/B] 8.3 snmpd i want to caluculate difference between two files fifth column(i.e bolded columns as mentioned above).. thanks in advance...:'(:) |
|
Re:
I'm looking for a way to get the first letter of of a string. I already know about the .startswith() but that is for "if" statements I want something like [CODE]print text.startswith() # to give me the left most symbol[/CODE] |
|
If I have example code: [CODE]url = "someurl" values = {"username" : USERNAME, "password" : PASSWORD} data = urllib.parse.urlencode(values) req = urllib.request.Request(url, data) urllib.request.urlopen(req)[/CODE] it passes username and password to the url that you request. So I want to post a thread in a forum. When I look at the … |
|
I have a class with a button, it runs the command automatically when the gui is constructed (which i dont want it to do) but then doesnt work again after. What am I doing wrong? Builtin commands such as endcommand work as they should. relevant excerpts (ignore the indent problem … |
|
hypothetical say i have [code] for i in range(20): for j in range(20): for k in range(20): [/code] How could I != all fo them without writing 20 statements i !=j !=k doesnt work obviously (I have to compare 5 words so writing a seperate for each combination would take … |
|
Re:
How to make a program in python to do this? 20% of the score comes from the average of 8 Quizzes (each has maximum of 10 points) 20% of the score comes from the average of 2 exams (each has maximum of 100 points) 40% of the score comes from … |
|
Re:
How do you use a variable originally from a def function? |
|
So I'm trying to make a parser for a game replay. I just need help getting started, I have docs for it explaining. Atm I'm just trying to get the header parsed. [code] replay = open(r'C:\Users\CookieMonster\Desktop\mix.w3g', 'rb') #offset | size | description print(replay.read(0x1c)) #0x0000 | 28 chars | zero terminated … |
|
***Editted: added second problem I have this code, how do I make it stop once it's found the first instance of the [B]if[/B] happening. break, myparser.close(), and return don't work. [CODE]from html.parser import HTMLParser class MyHTMLParser(HTMLParser): def handle_starttag(self, tag, attrs): if tag == 'a' and (attrs[0][1].find('downloads&showfile') != -1): print(attrs[0][1]) print(attrs[1][1]) … |
|
I'm trying to make a script that downloads from a specific website etc... it's done and everything. The problem is I need to compile it to a .exe for people to use and I noticed there isn't a py3exe to do this... So I downloaded python 2, and tried to … |