20 Discussion / Question Topics

Remove Filter
Member Avatar for
Member Avatar for DS9596

How does an array variable indexing expression differ from an array definition size expression?

Member Avatar for rubberman
0
136
Member Avatar for Jenelia89
Member Avatar for echocoder

I have a nested list, named env, created in the constructor and another method to populate an element of the grid defined as below: ... class Environment(object): def __init__(self,rowCount,columnCount): env = [[ None for i in range(columnCount)] for j in range(rowCount) ] return env def addElement(self, row, column): self[row][column] = …

Member Avatar for echocoder
0
1K
Member Avatar for jumboora

Hi, I have a text file in which there are 10000 lines. There are 225 numerical values on each line and each numerical value is followed by a index number and a colon e.g., 1:0.021354 2:0.125432 3:451321 ...... 225:0.001254. Now I want to remove this indexing. I know how to …

Member Avatar for nmaillet
0
193
Member Avatar for henry.sj.shin

Hello All, I'm trying to write a function that outputs the reverse of the input. I know that you can use the built-in list.reverse() or S[::-1] methods, but I want to make it using the 'for' loop. My code initially is: def reverse(S) for x in S: print(x, end = …

Member Avatar for TrustyTony
0
390
Member Avatar for jumboora

Hello Guys, My job is to process the text files. following are the steps that i have to do. 1: To combine multiple text files into one text file 2: Add filename (but without extension) in the beginning of each text file. 3: and Finally, index the contents of the …

Member Avatar for jumboora
0
2K
Member Avatar for effBlam

Im trying to find the first element in each nested list: x = [['hey','wassup'],['are','you','ok'],['i','am','fine'] So that I get print a string: "hw ayo iaf" so far I have: def first_letters(): x = [['hey','wassup'],['are','you','ok'],['i','am','fine'] Thanks!

Member Avatar for Gribouillis
0
89
Member Avatar for effBlam

Im trying to get the last element in each nested list such as double list = [['Hello','how','are','you'],['I','am','fine'],['How','about','yourself']] so that it will print out ['you','fine','yourself] I am also trying to do this all under a function such as def last_words(): #where my double_list is already in this function Thank you!

Member Avatar for Gribouillis
0
86
Member Avatar for Allison2009

I find something strange about Google Indexing. More than half of the products were indexed by Google sometime back. They reduced the indexing pages and after a while (in a week), only 1/4th of the indexed pages were shown as getting indexed. But when I search for a product, even …

Member Avatar for claydcousta
0
213
Member Avatar for teambuilding

Hi guys, I need to ping a few hundreds of backlinks as only some actually are indexed. Could you please advise what is the best way of creating an RSS from the multipple URLS (hundreds). I remember in the past trying some site that creates RSS feed from the list, …

Member Avatar for antesnop3
0
129
Member Avatar for durhamandy

I am trying to find the position of the maximum number in a 2D array. i have used .max() to find the max value but how do i find its position?

Member Avatar for vegaseat
0
242
Member Avatar for gutchi

Hi everyone! So here's my problem: Given an element, I need to get the index of the array in an array of arrays. For example, I have the following array of arrays: [CODE] my @arrOfArr = ( [ "1023", "1472", "0751651"], [ "1527", "1167", "2496111" ], [ "M167", "1412", "1761683" …

Member Avatar for gutchi
0
215
Member Avatar for manshipboy

I am trying to generate a new checkbox in a different form. [code] Public Class frmAdd Public Sub btnitemadd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnitemadd.Click Dim chklowerleft As New CheckBox Dim chkhandleft As New CheckBox Dim indexcounter As Integer = 4 If chkleftlowerarm.Checked = True Then frmMain.chklistLA.Items.Add(chklowerleft, …

Member Avatar for Unhnd_Exception
0
141
Member Avatar for arnoldcadman
Member Avatar for jkon

Hello all, I have a table dir_records < SHOW CREATE TABLE dir_records > CREATE TABLE `dir_records` ( `ID` int(11) NOT NULL AUTO_INCREMENT, `TITLE` varchar(250) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL, `URL_TITLE` varchar(250) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL, `TXT` text CHARACTER SET utf8 COLLATE utf8_bin NOT NULL, `COMPANY_ID` …

Member Avatar for smantscheff
0
167
Member Avatar for cptspock

You guys were so kind in helping me resolve my database connection problem, my web page is up and running with connections to the database working just great. Thank you all. Now I am just having a problem getting the Search to work. My web search requests return the following: …

Member Avatar for cptspock
0
267
Member Avatar for jeffsbaker

I was wondering if someone could help me with a mysql indexing problem. The index of 'username' for this code works fine: [CODE=mysql]EXPLAIN SELECT count( * ) AS num_messages FROM messages, users WHERE messages.username = 'johndoe' AND users.username = 'johndoe' AND messages.sent_date >= users.last_activity[/CODE] Here is the explain: [code] id …

Member Avatar for jeffsbaker
0
348
Member Avatar for Allison2009

Hi, I have given around 5 links to a particular page of my website. They were from good PR4 and above Article Websites. But still I find those pages are not indexed by google. It is a Shopping Cart Website. The contents are also good enough. Hence can't blame contents …

Member Avatar for Lecee Lery
0
212
Member Avatar for ozone_tom

I have a spreadsheet (roughly 200x200 in size) that is a matrix of 0's and 1's that define rules. These rules cannot be expressed in procedural logic because they need to be easily accessible for change by a user for modification. The first row are header value strings and the …

Member Avatar for ozone_tom
0
297
Member Avatar for kirtan_thakkar

I have a complete list of a topics. I have to create a Index for A B C D E ... On Clicking those buttons without navigating to another page it shows only topics wich starts from that letter... How to code it in php???

Member Avatar for kirtan_thakkar
0
155

The End.