Questions tagged [list]
The list tag may refer to: a linked list (an ordered set of nodes, each referencing its successor), or a form of dynamic array. Not to be used for HTML lists, use [html-lists] instead.
8
questions
0
votes
3
answers
31
views
How to call a number from a multi-dimensional complex list
I'm trying to make a sophisticated quiz that involves a list for a question and an answer that is included in a list. I want to call numbers from this multi-dimensional list using a "for" ...
0
votes
0
answers
38
views
Difference between appending a list and appending a copy of list [duplicate]
I need to understand the difference between appending a list and appending the copy of a list in python.
This is the code:
res=[1,2,3]
res1=[1,2,3]
c1=[5]
res.append(c1.copy())
res1.append(c1)
print(...
-1
votes
5
answers
50
views
Focusing on an element of a subset, of a subset
Fairly new to coding and I have a question regarding list and subsets.
Suppose this is my list:
list =
[[[a,2], [c,3], [e,3]],
[[g,4], [i,4] [k,3]],
[[b,3], [d,2], [f,2]]]
How would I go about making ...
0
votes
1
answer
41
views
List of controlled components in React
I am trying to have a list of components where each one takes user input and have a separate state.
I want then to be able to filter this list and get the components where for example "switch&...
2
votes
2
answers
40
views
How to match elements from input to list
I'm currently working on a Caesar cipher program, and I basically typed up a list of the alphabets: alphabet = ['a','b','c','d',...]
Then asked the user for a word to encrypt, text = input('Enter your ...
3
votes
0
answers
46
views
How do I iterate over a sublist of a SynchronizedList in Java?
What kind of synchronization should I use to iterate over a sublist returned from a SynchronizedList as a result of subList() method invocation?
The documentation for Collections.synchronizedList() ...
0
votes
0
answers
28
views
Navbar list items being disrupted with image [closed]
Need some help on why my links aren't positioned where they should be.
Only the :first-child seems to be aligned where it should.
* {
margin: 0;
padding: 0;
}
body {
min-height: 100vh;
...
0
votes
0
answers
17
views
How to completely fill a Section (or use a custom shape for a Section) in an .insetGrouped List? [duplicate]
Given a List with insetGrouped listStyle, how can I fill the contents of a Section such that no padding is visible?
In the follow example, I have a Rectangle overlaid with a Button. The Rectangle (in ...