659 Topics

Member Avatar for
Member Avatar for Niloofar24

Hello. I have a list: mylist = [2,4,4] How can i take number 244 out from the list? Something like: number = 244 Here 244 is integer.

Member Avatar for vegaseat
0
283
Member Avatar for Joemeister

Hi all, I'm trying to access a list in a class made in another class and display it in a listbox but its not working. I most probably have to make a small change to be able to get it to work. So please check in the code if you …

Member Avatar for djjeavons
0
5K
Member Avatar for Niloofar24

Hello again. How can i limit my list indexes? I want my list to take only 3 indexes for example.

Member Avatar for Niloofar24
0
603
Member Avatar for Niloofar24

Hello. mylist = [6, '/', 3, '+', 9, '+', 8, '+', 1, '/', 2] How can i delete that list indexes? I tried: def clear(self, event): global numbers for i in numbers: print i del numbers[i] But it didn't work: File "./kivycal", line 83, in clear del numbers[i] TypeError: list …

Member Avatar for Niloofar24
0
274
Member Avatar for Niloofar24

Hello. I have a list like this: mylist = [7, "+", 2, "+", 1] I want to take them out of the list inorder to run the operation and get the real result; something like this: result = 7 + 2 + 1 So the result variable will be set …

Member Avatar for Niloofar24
0
332
Member Avatar for ogsirus

Hi Guys, Im a bit puzzled on the best way to store data which will later be saved to a csv. I am doing a record search on a database table which will get cycle through each employee and get the relevent information. Once I have done this I will …

Member Avatar for deceptikon
0
301
Member Avatar for Niloofar24

Hello! My this time question is about breaking a list. I have a list with the name favorite_movies. Here is 2 functions of all functions from the file: def add(): load_favorite() favorite_movies.append(ent.get()) dump_favorite() #print (colors) def view(): load_favorite() from Tkinter import * v = Tk() v.geometry('300x300') v.configure(background = 'white') top …

Member Avatar for Niloofar24
0
559
Member Avatar for PulsarScript

//Hi all just switching from c++ to c#.Can anyone help,with the question i have: //this is a peace of code from c++ banking aplication int ShowMenu(void); void AddAccount(vector<CAccount*>& list); void DisplayAccount (vector<CAccount*>& list); void Lodgement (vector<CAccount*>& list); void Withdroawal (vector<CAccount*>& list); void InterestRate (vector<CAccount*>& list); CAccount* findAccount (vector<CAccount*>string ); bool …

Member Avatar for ddanbe
0
2K
Member Avatar for ddanbe

Looking on the web for how to do it. Found several solutions: serialisation, XML etc. Cannot decide which to use. My List class contains a string, some booleans and two other Lists. Awaiting some opinions that will be accepted with great gratitude. :)

Member Avatar for ddanbe
0
235
Member Avatar for senait.kifle.127

My Objective is to define a function, with a pointer to a list of elements of the structure I created as the first parameter, a C-character string (of type char * ) as the second parameter and one of the of the two values,num or name, from the above enumeration …

0
176
Member Avatar for kortneycoles

I'm working on this code for class, I am not expecting anyone to do my homework but help would be appreciated. Nodes are confusing for me and my professor did not explain well. The errors I am getting are where I declare the functions, I dont know the nodeType(?) that …

Member Avatar for nataraja833
0
333
Member Avatar for flebber

This is a simple problem that for some reason I can't get to work. The problem I created for myself was to use call a function from a function using *args and print out the question and solution. I want the output to vary as the *args can accept any …

Member Avatar for flebber
0
294
Member Avatar for sudesh.yadav.104

HI I donot understand where to start . I need ideas and help. void InsertList(c4735list *destinationList,c4735list *sourceList,node *startNode) { //=====================not implementd yet } this fn inserts source list into destination list.the nodes are inserted after the startnode in destination list.source list should be an empty list after this operation. the …

Member Avatar for sudesh.yadav.104
0
265
Member Avatar for sneekula

I would like to break up a list into sublists of 3 elements each. I have this code, but it will give an index error when the length of the list is not divisible by 3. mylist = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11] …

Member Avatar for sneekula
0
258
Member Avatar for Joemeister

I have troubles trying to display a list of items/objects in a array. What I'm doing is I'm adding students with a name, surname, age, and marks for subjects (Properties) to an array. If I added 4 students in this manner to the list I want to display all the …

Member Avatar for Joemeister
0
285
Member Avatar for chophouse

I've written this function to take a list and shift each member right by the number supplied as the offset. I want to preserve the supplied list and return the shifted list. My problem is that the function modifies the supplied input list itself as well as returning a new …

Member Avatar for chophouse
0
291
Member Avatar for Sammys.Man

Hi guys, im working on a bit of code which for 2 days is sending me around in circles :/ what i want to do is split an array into variables, so i can dynamically create a text box. i'm trying various methods but think im chasing my tail now. …

Member Avatar for cereal
0
190
Member Avatar for can-mohan

Hi Guys, Any body knows what is the efficient way to create the map (key,value pair ) using linklist using c .Apart from this in this map one key can have multiple values and i need to display those values. I don't want implementation in c++. example string1->"james" string1->"mike" string1->"harry";

Member Avatar for Schol-R-LEA
0
2K
Member Avatar for Bradoz

Hello below is my code for a program that reads in integers rom keyboard input and creates two polynomials from that input and then does some maths functions on them. I've got the addition working, having trouble with the multiplication though. Any help would be appreciated. thanks import java.util.*; import …

Member Avatar for JamesCherrill
0
3K
Member Avatar for network18

Hi, I have come across another programming challenge again and hopefully I wont close the thread myself this time. I am expecting good suggestions or examples from you to do this. I want to build a (scrollable) nested list, from which children of two parents could get swapped after some …

Member Avatar for Traevel
0
194
Member Avatar for iConqueror

I am doing a little home project to learn more about collections and FileIO. I have made a little racing app where the user enters the racers details all of which are strings, and these details are inserted into a List<T> list and then once the user clicks the 'save' …

Member Avatar for tinstaafl
0
326
Member Avatar for Khalilur_1
Member Avatar for ClaudeRhay

Say I have this definition: #define SIZE 2000 typedef enum { TRUE, FALSE }Boolean; typedef struct{ char jobTitle[30]; char jobDesc[255]; char jobLoc[255]; float salaryMin; float salaryMax; Boolean isAvailable; }jobInfo; typedef struct cursorNode{ jobInfo jobRec; int next; }HeapSpace[SIZE]; typedef struct hnode{ HeapSpace heap; int Avail; }*VHeap; typedef int List; typedef struct{ …

0
190
Member Avatar for iConqueror

I know that the main difference between an array and a list is that a list size changes dynamically as items are added or removed. Because of this, if we copy an array to a list does that mean that the list must have a static size of the array's …

Member Avatar for deceptikon
0
176
Member Avatar for iConqueror

Both lists and arrays store data in one object(array or list). 1. In C# what is the difference between arrays and lists? 2. Can we store the same type in a list as an array? 3. Can an list store objects and references to other objects? 4. Where would we …

Member Avatar for tinstaafl
0
194
Member Avatar for sys73r

I'm working with a LIST that am getting from a soup which after the clean up gives me: lists of variable length ['7.0', '7.5', '6.8', '6.9'] or ['7.0', '7.5'] so my problem is when I try formating the output: code snippet: if grades: print '\r\n["' + str(student[0]), if len(grades) == …

Member Avatar for David W
0
391
Member Avatar for Olyboy16

Please geeks how can i use/access the initialization list for my class. So that can do something like this... MyClass foo = {value,value,value};

Member Avatar for Olyboy16
0
98
Member Avatar for abaddon2031

I have a small program that searches through two folders and gets the size of the files in them. As of right now for every file that is over the specified size limit sends a email. What i am wanting to do it have it compile a lsit of the …

Member Avatar for TrustyTony
0
279
Member Avatar for dany12

Based on this ideea **You just wrote a loop allowing the input of 20 names into a list. Alas, you made an error as you entered name number 17. Redesign your input loop, so you can correct the error easily without having to retype the previous 16 names.** I wrote …

Member Avatar for TrustyTony
0
319
Member Avatar for poochiteap

want to create an archive list like this: 2014 -March -Feb -Jan *Post 1 *Post 2 2013 -November *Post 1 My config file is: <?php ob_start(); session_start(); //database credentials define('DBHOST','127.0.0.1'); define('DBUSER','name'); define('DBPASS','pass'); define('DBNAME','sample'); $db = new PDO("mysql:host=".DBHOST.";dbname=".DBNAME, DBUSER, DBPASS); $db->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); //set timezone date_default_timezone_set('Europe/London'); ?>` the table I m using …

0
273

The End.