Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
Unknown Quality Score

No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.

0 Endorsements
Ranked #12.3K
Ranked #2K
~14.3K People Reached
Favorite Forums
Favorite Tags
Member Avatar for mahela007

Occasionally I need to make files in certain folder using python. To minimize the clutter which such files might cause I would like to make them hidden. It's pretty easy to do this using windows explorer but I have to do it manually for every file which my script creates. …

Member Avatar for mahela007
0
12K
Member Avatar for dinilkarun

data='115Z2113-3-777-55789ABC7777' I have a string in the above format. I want to remove 'ABC7777' from it. If there are any characters other then numbers after the right most '-' symbol, then only the string preceeding it should be retained.i.e., '115Z2113-3-777-55789ABC7777' should be stored in data. 'ABC7777' should be stripped off. …

Member Avatar for woooee
0
411
Member Avatar for haikur

Hi everybody! I'm trying to write a program that is able to look inside a txt file and change, for example, the first word with a similar word. The txt file will have one word for line. EXAMPLE::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: ORIGINAL TXT FILE: tom lives CHANGED TXT FILE: mum lives :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: I …

Member Avatar for Miyuki
0
126
Member Avatar for Agni

Hi, When i search for a pattern in a file how do i get the line and line#? basically i want to replicate the 'grep' command functionality. Now i can easily say whether the pattern exists or not using re.search funtion but i'm not able to print that particular line …

Member Avatar for Agni
0
122
Member Avatar for reyev

Hi everybody! I need to split my path, let's say' "C:\path1\path2\path3\path4" into separate strings... Not sure how to do that, I've tried os.path.split / splitdrive etc. but it always give me just 2 arguments I need to get "C:\path1" from this path string for example, which would be the root …

Member Avatar for reyev
0
130
Member Avatar for parmenio79

I have a list of document pages with indicators where each document begins "ND": [CODE] Page1,ND Page2, Page3, Page4,ND Page5, [/CODE] I am trying to format it so that I have a two column csv with the first and last page: [CODE] Page1, Page3 Page4, Page5 etc [/CODE] I cannot …

Member Avatar for rikxik
0
81
Member Avatar for FreezeBlink

At various points in my text-based programs, I've had to write a function for use in multiple-choice menus. It needs to have the following qualities: [list][*]Ignores non-number input, repeating the request if it is given a string. [*]Can be given upper and lower limits on the acceptable numbers, repeating the …

Member Avatar for rikxik
0
84
Member Avatar for FreezeBlink

This is probably totally absurd, but...is it possible to, through Python, access the command line and use it? For instance, write a program that outputted all of the files in a given directory, much like cd [directory] dir would?

Member Avatar for rikxik
0
188
Member Avatar for sanoski

I recently bought a book on Python, and I'm working my way through it. However, I've come to a very simple program, but I can't understand a certain part of the code. Can someone explain? [QUOTE]# Print out a date, given year, month, and day as numbers months = [ …

Member Avatar for sanoski
1
263
Member Avatar for wyno

hi there, my 1 year old carpet python is eating a jumbo rat every 3 days wat is the next thing to feed after jumbo rats please advise thanks wyno

Member Avatar for Ene Uran
0
73
Member Avatar for rysin

If I have something like this [CODE] a = input("Number: ") b = 2 + a [/CODE] How do I make the answer of b the name of a file? Thanks!

Member Avatar for 1337455 10534
0
129
Member Avatar for 1337455 10534

So I have a pyGTK app going on nicely, but it requires sudo permission (under Linux) to perform a BASH operation. If I prompt for a password using a GUI, is there any way I can do my BASH stuff without sudo asking the user for a password in the …

Member Avatar for 1337455 10534
0
200
Member Avatar for volcs

I have been scripting with Python for a few years but I just recently decided to start using some OOP to make my life a bit easier. Although I've read many examples and some chapters and websites, some of the most rudimentary basics still elude me. Here is an example …

Member Avatar for katharnakh
0
102
Member Avatar for Zelores

Hi, I just joined today and i need some help with python. I just started using python not to long ago in my intro programming class. We have an assignment coming up and i need some help. How do you get the sum of an integer. ie: you put in …

Member Avatar for Zelores
0
195
Member Avatar for cdfd1982

A file is ELL[COLOR="Red"]P[/COLOR][COLOR="Red"]S[/COLOR]YST[COLOR="Red"]A[/COLOR]TL ELL[COLOR="Red"]S[/COLOR][COLOR="Red"]U[/COLOR]YST[COLOR="Red"]L[/COLOR]TL * * *[COLOR="Green"] : . [/COLOR]* * *[COLOR="Green"] :[/COLOR]* * H[COLOR="Red"]H[/COLOR]ULJKL[COLOR="Red"]O[/COLOR][COLOR="Red"]P[/COLOR]OA H[COLOR="Red"]P[/COLOR]ULJKL[COLOR="Red"]P[/COLOR][COLOR="Red"]O[/COLOR]OA * [COLOR="Green"].[/COLOR] * * * * *[COLOR="Green"] : : [/COLOR]* * and it is a long file ..... so output shud be where there is[COLOR="Green"] : [/COLOR]and [COLOR="Green"].[/COLOR] counting start from E and …

Member Avatar for rikxik
0
138