Questions tagged as 'lista'

3
answers

Make copies of lists in certain positions with Python

Hello, please, I would like to copy a certain list in python. The total size of the list is 150 and I want to remove the last 50 items from the list. Here I will represent a list 100 times smaller, that is to say with 15 elements and that I want...
asked by 17.07.2016 / 03:39
1
answer

Is there a performance difference between Tuple and List?

In Python, I know there is a difference between a Tuple and a List . The Tuple is immutable, and the List , changeable. You may already have this question here: What is the main difference between a Tuple and a List...
asked by 16.11.2016 / 16:41
2
answers

Pick values from a dynamic list

I have a list of type dynamic : private List<dynamic> listServicos = new List<dynamic>(); And it's being populated like this: listServicos.Add(new { Codigo = txtCodServico.Text, Servico = txtNomeServico.Text, Quantidade...
asked by 28.12.2015 / 16:37
1
answer

Cross-Reference with vector of pointers

I am creating a cross reference of a vector of pointers that calls a simple linked list. Aim is to type a sentence and decompose your words, placing them in each position of the vector according to their respective initial letter. #include...
asked by 12.10.2018 / 16:22
2
answers

Add all Environment elements to a list automatically

Suppose my Environment contains the following objects (dummy names): abcd # numeric efgh # dataframe ijkl # matrix mnop # character My goal : Put them in a list automatically, without typing: mylist<-list(abcd,efgh,ijkl,mnop) Is th...
asked by 09.10.2018 / 16:03
1
answer

How to modify an element inside a list in Python?

I have the following list: pessoa=("Filipe", 40, True) I write the print command for each element: print(pessoa[0]) print(pessoa[1]) print(pessoa[2]) The answers are: Filipe 40 True When I try to modify the first element: pessoa...
asked by 10.02.2018 / 07:52
1
answer

list assignment index out of range

A part of my Python program is: dt=1 maxt=3600*2 t=range(0,maxt,dt) r=len(t) Tsup_i=20 for i in range(1,r): Tsup[0]=Tsup_i P[i]=((I_dc)**2) * R20 * (1 + a * (Tsup[i] - (20+K))) And the error is appearing    "IndexError: list ass...
asked by 15.02.2016 / 11:51
1
answer

Search for item [List]

I want to search an element of a list by a name (vector of characters). I get the name (espm) in function and childbirth for the search. The problem is that the function always tells me "There is no doctor with this specialty" even when the na...
asked by 23.08.2016 / 02:46
1
answer

Read rows and columns by Python, by excel

My question is if you have any resources so that I can read excel rows and columns. For example: I have experimental data in excel containing header in the first row having some 12 columns of data, then [1:12] it would only be the header, and so...
asked by 10.11.2015 / 18:10
1
answer

Sorting list

I'm doing a work that I need to create a linked list and sort it in ascending order, doing my tests, I realized that I'm missing a reference to a node, the problem may be logical but I can not find my error. > method to add and sort: public...
asked by 28.06.2015 / 22:34