- Upvotes Received
- 1
- Posts with Upvotes
- 1
- Upvoting Members
- 1
- Downvotes Received
- 3
- Posts with Downvotes
- 2
- Downvoting Members
- 3
Re:
After you got the basics of Python under your belt, the best way to get a good knowledge of the language and improve your coding skills is to start on a project you are interested in. Maybe an image viewer, a slide show, computer generated random or fractal art, a … |
|
Here is a plan for a (relatively) random numeric dictionary I've put together. I'm hoping that people can help me refine the plan so that I can start incremental coding: #! usr/bin/env python # creates a random dictionary from random import randint # user inputs maximum length of dictionary # … |
|
"Active cracking" means indirectly changing a plaintext message so that it becomes a totally different, plaintext message that says something totally different but still makes sense, by creating a brand new encryption key that is applied to the ciphertext itself and changes the ciphertext rather than the original plaintext. I … |
|
Re:
I can't find anything to help me out on this method of sorting. How do I do it? |
|
Re:
Last week I bought a new [Lonovo G505 laptop](http://shop.lenovo.com/gb/en/laptops/essential/g-series/g505/) for the purpose of installing Linux. After removing Windows 8 I tried to install three different linux distributions, none of them worked. None had a compatible wifi device driver, and none of them could start the X server after installation was … |
|
The Software Manager offered both python-tk and python3-tk for install, so I installed both. The latter permits me to import tkinter as a whole, while the former does not. Instead, the python 2.x version chopped tkinter up into several submodules that must be imported separately, which is a major nuisance. … |
|
Re:
![b62b330b33236e12160db60d6c858d9d](/attachments/small/3/b62b330b33236e12160db60d6c858d9d.JPG "align-right") booted from a flash drive to go into the live cd mode , there , as soon as i double clicked a flash video , the screen went all jumbled up , and my pc hanged up. later i tried to check it in oracle virtual box , … |
|
Re:
def main(): print ('Welcome to the mpg calculator program') print() #get the miles driven using the input function miles_driven = input ("Please enter miles driven: ") miles_driven = float (miles_driven) #get the gallons used using the input function gallons_used = input ("Please enter gallons used: ") galons_used = float (gallons_used) … |
|
Re:
develop a program which asks for a name and a password,and prints an acceptance message if the name is "aladdin" and the password is "sesane".the program should print a reject message in all other cases.this should be achived by combining the two tests into one using the "and"key word |
|
This error frustrates me when I want to iterate over the elements of a set, for example when trying to convert the set to a list. How do I get around it? |
|
As I've learned more about basic console Python script writing, I've had a look at both Tkinter and GTK+...and, at first glance, I like GTK+ better. Which do you guys prefer, and why? |
|
Which of these is the best practice for executable Linux scripts: #! usr/bin/env python #! usr/bin/python #! usr/bin/env python3 #! usr/bin/python3 All four of them work just fine on my system, so I'm looking for the best practice. Thanks. |
|
This code: def reverse(x): for i in range(len(x)): y[i] = x[-(i+1)] return y a = [1, 2, 3, 4, 5] b = reverse(a) returns a "global variable 'y' not defined" error. WHAT GLOBAL VARIABLE????? If I add 'y = []' anywhere in the code, either inside the function or outside … |
|
I had a function all by itself in the file [filename].py, and the file was properly executable. This is how people advised me to call it externally: import func func.[filename]() But I was getting errors all over the place. So I contacted Python help and they told me something different, … |
|
Okay, so cryptography is insanely well developed and I'm not doing anything new here, but I still thought I'd monkey around with a cryptography project. Here's what I want it to do: 1) generate an encryption and decryption key that is randomly between 20 and 40 digits long and contains … |
|
Suppose you have this file named func.py: def func(x): y = raw_input(x) return y func(z) And then you have this calling code: z = raw_input('Type a request for input and hit enter: ') omega = execfile('func.py') print(omega) Why does the output always end up being "None?" |
|
Re:
Here is exercise in error handling, while looping and for looping with itertools.chain. It is also exercise of functions not letting user to go without giving proper input. I call them to myself 'jail functions'. Here you could add as an exercise breaking out of loop and continuing until user … |