Posts by Durval Carvalho • 405 points
11 posts
-
0
votes1
answer29
viewsA: How do I create a dynamic link to a Django admin screen?
When a class that inherits from the Django.contrib.admin class is registered, Django records the views associated with the following pattern: Dashboard with the list:…
-
-1
votes1
answer29
viewsQ: How do I create a dynamic link to a Django admin screen?
How to use the tags of the Django templates to create a dynamic link to the admin boards? Let’s say the name of the admin panel is ProductsAdmin, and that this table was created and registered in…
-
2
votes0
answers47
viewsQ: How do I transfer responsibility from a pointer?
During the implementation of the Pattern Command design, I came across the following dilemma: "As I signal to customers of a particular class, the pointer passed as parameter will be destroyed?". To…
c++asked Durval Carvalho 405 -
7
votes1
answer85
viewsQ: How is it possible for the same memory address to have 2 different values at the same time?
I had a question about the behavior of the type qualifier const of the C++. I was testing how much a variable declared as a constant is protected from changes. For this I tried to change its value…
-
1
votes1
answer42
viewsQ: Composite foreign key - ERROR 1215 (HY000): Cannot add Foreign key Constraint
I during the creation of these 3 tables came across the error: "ERROR 1215 (HY000): Cannot add Foreign key Constraint" The only conclusion I could come to is that the problem lies with the field…
-
0
votes1
answer105
viewsA: What are the differences between these two ways to save form information?
I got an answer on stackoverflow in English that cleared the doubt. The translation I made was like this. You can only use the form.save() when the form class inherits from ModelForm. Overall this…
-
0
votes1
answer105
viewsQ: What are the differences between these two ways to save form information?
I am learning how to use Jango forms and I have been presented with two ways to save information from a form in a database. I tested both and both work with validations, but did not understand what…
-
14
votes2
answers128
viewsQ: What are they and when to use Anonymous Unions?
During the data structure book reading, it was briefly presented the concept of anonymous unions, which would be the definition of a union without specifying a label (name). However, I did not…
-
1
votes1
answer661
viewsQ: How to reduce the runtime of a python script?
I have been for a few days trying to solve a programming problem that involves searching to find the union and the intersection between sets. I managed to solve the problem with small sets, but when…
-
2
votes0
answers321
viewsQ: How to Make Multiple Threads in a Java Loop
Description of the Problem I’m making a Pokedex, in which one of its features is to filter all the Pokemons of a certain type. I managed to implement this functionality, but the execution time is…
-
3
votes1
answer557
viewsQ: Count how many columns are in a C++ CSV file
I am doing a design of an electronic ballot box, and for that I need to read a csv file where there is information about each candidate. As this csv file has a lot of information that is not…