Posts
 
Reputation
Joined
Last Seen
Ranked #57
Strength to Increase Rep
+14
Strength to Decrease Rep
-3
92% Quality Score
Upvotes Received
916
Posts with Upvotes
812
Upvoting Members
325
Downvotes Received
66
Posts with Downvotes
60
Downvoting Members
38
192 Commented Posts
~3.71M People Reached
About Me

IT Pro doing Eng-Fin-Eng translations

Interests
Family values, world peace, translation, Python
PC Specs
Asus i7-3770 @ 3.4 GHz, 8 GB, 1.5 TB / TUF Gaming 10th gen laptop
Favorite Tags
c x 224
c++ x 179
list x 178
tkinter x 137
Member Avatar for masocha

Please assit to translate the following code from python to php [Click Here](https://www.dropbox.com/s/qndlm9qenvge6sf/pyussd.rar) Thank you

Member Avatar for Mike_106
0
6K
Member Avatar for isendre

Hi everyone, I'm having trouble creating a program. This program needs to create a square board of size n, where a user inputs an integer value 2 - 9. For example, a board with size n=4 would look like: 1 . . . 2 . . . 3 . . …

Member Avatar for cossy254
1
6K
Member Avatar for RoqueyB

so i have an assignment for a class to make a pick up sticks game. This is the actual assignment: "The rules of pick up sticks are as follows: The user chooses the number of matchsticks (5 to 50) to place in a pile. Then, the computer chooses who will …

Member Avatar for Ben_493
0
8K
Member Avatar for colby.christensen

Years ago I wrote a program in Fortran for a structural analysis class. At the time I had very little programming experience and mottled my way through the assignment. Fast forward to now and I'm attempting to teach myself Python 3. I figured I'd would try to convert the old …

Member Avatar for Reverend Jim
0
4K
Member Avatar for WolfShield

Hello everyone, I am writing a program that has a part where the user can type in notes, and I would like the program to insert the date and time into the beginning of the note. I have the time and date part figured out: [CODE] import datetime now = …

Member Avatar for Ajeet_8
0
10K
Member Avatar for markusd5454

Below is a program that asks the user to input a username and password. Once logged off the user is asked to re-enter their username and password. Is the program correct where it checks if the username and password input before is correctly input again?. Any help would be welcome …

Member Avatar for Reverend Jim
0
86K
Member Avatar for guidely

Hi, I try to convert the c code into python it actually complie but no result came out Code in C #include <stdio.h> # include <math.h> double const pi=3.1415926535897932384626433; double const twopi=2.0*pi; double const halfpi=pi/2.0; float cos_32(float x) { int quad; x=fmod(x,twopi); if (x<0) { x=-x; } quad=int(x/halfpi); switch (quad) …

Member Avatar for Sukant_1
0
18K
Member Avatar for pelin

i am almost done with the hangman game but i just need to migrate it to graphics i know i need to use entrybox but i still dont know. [CODE]rom graphics import* from random import * MAX_BAD_GUESSES = 7 def readfile(): infile = open("wordlist.txt","r") contents = infile.read() lines = contents.split("\n") …

Member Avatar for Devarshi_1
0
628
Member Avatar for Peter_TARAS

Hello, I am learning Tkinter. As a part of the learning process I am building a Notepad clone in order to become familiar with Tkinter widgets. I am pretty close to completing it - I added about 90% functionality to the application - but I face two problems: 1) The …

Member Avatar for bevis.hobbs
0
22K
Member Avatar for daviddoria

Is there a library that has a function that will take (theta,phi) and return (x,y,z)? Thanks, Dave

Member Avatar for Ratan_2
0
6K
Member Avatar for vegaseat

This simple isprime(number) function checks if the given integer number is a prime number and returns True or False. The function makes sure that the number is a positive integer, and that 1 is not considered a prime number. To find out if an integer n is odd one can …

Member Avatar for amir_19
3
24K
Member Avatar for Iceman10284

Design a function named max that accepts two integer values as arguments and returns the value that is greater? For example: if 7 and 12 are passed as arguments to the function, the function should return 12. Use the function in a program that prompts the user to enter two …

Member Avatar for UNIQUE_PRINCE
-1
4K
Member Avatar for tjsilver

Hello, I found this code in a thread from about 18 months ago in a post by 'woooee' - [CODE]def func_1(): print " func_1 test" def func_2(): print " func_2 test" def func_3(): print " func_3 test" def func_4(): print " func_4 test" ##---------------------------------------------------------------- ## dictionary = list of function …

Member Avatar for August.Garcia
0
3K
Member Avatar for vegaseat

This short Python code gets the local time from the PC as a formatted string using time.strftime('%H:%M:%S'). The time string is displayed in a label using a larger font. A recursive function checks the time five times per second, and updates the time string, if it has changed. Five times …

Member Avatar for Vinay_17
2
26K
Member Avatar for sarfrazashfaq

HI All! I need to have some help. I have a python function name is abc.py and variable is declared in abc.py, variable name is 'uname'. How can i call variable name 'uname' of abc.py in my batch file name testing.bat and get uname value in my batch testing.bat file? …

Member Avatar for jaakdentrekhaak
0
5K
Member Avatar for Fo.katia

Hello guys!! I really need your help, I'm starting to use python and I have to write a program that counts the letters of a sentence entered by the user. This is what I have so far, but I don't know why it is not working.. Please help, thank you …

Member Avatar for woooee
0
13K
Member Avatar for abders

This is my custom module: [CODE]class Player(object): def __init__(self, name, score = 0): self.name = name self.score = score def __str__(self): rep = self.name + ":\t" + str(self.score) return rep def ask_yes_no(self, question): response = None while response not in ("y", "n"): response = input(question).lower() return response def ask_number(self, question, …

Member Avatar for Kaushik_2
0
977
Member Avatar for abders

Hello, I was testing a class in a GUI, and that error message showed up. Please help. Code: [CODE]from Tkinter import * class Application(Frame): def __init__(self, master): super(Application, self).__init__(master) self.grid self.create_widgets() def create_widgest(self): self.bttn1 = Button(self, text = "I do nothing!") self.bttn1.grid() self.bttn2 = Button(self, text = "Me too.") self.bttn2.grid() …

Member Avatar for Gribouillis
0
2K
Member Avatar for TrustyTony

This is one small snippet of after event usage. You could express if you find this kind of simple code to be usefull as snippet. Notice also vegaseat's sticky message threads in begining of Python forum in addition to code snippets.

Member Avatar for Gribouillis
0
5K
Member Avatar for thinkerman

Hello. I'm having trouble with creating a program based on Prim's algorithm. This is the program and got the following error: #include<iostream> #include<stdio.h> #include<conio.h> using namespace std; int weight[20][20],visited[20],d[20],p[20]; int v,e; void creategraph() { int i,j,a,b,w; cout<<"\nEnter number of vertices"; cin>>v; cout<<"\nEnter number of edges"; cin>>e; for(i=1;i<=v;i++) for(j=1;j<=v;j++) weight[i][j]=0; for(i=1;i<=v;i++) …

Member Avatar for Aiman_1
0
1K
Member Avatar for sheltask

First I was on that console window, and everything seemed easy because I could break everything down and knew EXACTLY what I was doing to get what I wanted done. However, that boring text-window got tiring. I decided to move on, but that was the biggest mistake ever. For over …

Member Avatar for Less_1
1
812
Member Avatar for vegaseat

Another application of Python module base64, this time to embed midi music data in your program. You also need the module pygame to execute this Python code. Enjoy the music!

Member Avatar for Rufus_1
5
11K
Member Avatar for ruwach

Hey there. i want to set a variable to represent the last line of a text file how do i do that? or even better, how do i create a list of the lines of a text file? any suggestions?

Member Avatar for gunjan_3
0
63K
Member Avatar for vegaseat

Just a relatively simple calculator using the Tkinter GUI. It has a few nice features such as correcting division by an integer (for older Python versions), error trapping, to and from memory buttons, and an editable display. The editable display allows you to backspace mistakes, and also to enter things …

Member Avatar for Charles_24
5
10K
Member Avatar for Gribouillis

This snippet defines a function restart_program() which restarts your python program from within your python program.

Member Avatar for Gribouillis
5
74K
Member Avatar for tjy92

I need to write a program that reads data from a text file, and prints it. These are the specifications. And then manipulate the program to determine this: -The number of uppercase letters in the file -The number of lowercase letters in the file -The number of digits in the …

Member Avatar for Reverend Jim
0
3K
Member Avatar for sandman64

i'm trying to use the elif statement but every time i try to use it it gives a syntax error. here's the code: [code] n = input() while n != 2: n = n - 2 print "number is even" elif: n < 2: print "number is odd" [/code]

Member Avatar for Swathi_4
0
216
Member Avatar for Viasur

Hello to everyone! Yes, Im a newbie and I have a problem that is kind of a pain. I receive an error "Invalid Syntax", when trying to run this. The file mesaure.csv has been created and it is locate on the correct folder with the .py file. Whe I try …

Member Avatar for Gribouillis
0
4K
Member Avatar for tkpanther

Hello, it is me once more. I am using Python 2.3, and I must use Zelle's graphics class (and I must agree with many of you. Tkinter is much better). We have been tasked with creating a Graphical Scientific Calculator. In addition to the normal operators, it must contain the …

Member Avatar for Gribouillis
0
22K
Member Avatar for sabbib

I want to use Tkinter funtion to create a a temperature calculator. I have all the code for the calculator, however using Tkinter function i cant figure out how to get the variable input by the users. I am new to python and programming, just started programming less then a …

Member Avatar for Judith_2
0
1K