Posts by Sergio Souza Novak • 513 points
25 posts
-
3
votes1
answer786
viewsQ: How to trade two non-consecutive knots on a doubly chained list?
I needed to switch two consecutive knots or not on a doubly linked list, but I can’t. Can someone help me? I’ve even done it on paper but it doesn’t perform. What’s wrong with the code? void…
casked Sergio Souza Novak 513 -
1
votes0
answers125
viewsQ: how to traverse a pointer to set in c++?
Hi, I’m implementing Kruskal’s algorithm, but I can’t navigate one set< No*>* to test the FIND_SET method, which is a set< No*>* how should I proceed? (in the rest of the code I walked…
-
1
votes0
answers82
viewsQ: is a binary recursive or iterative search better?
I don’t do PAA (Design and Analysis of algorithms) but I would like to know the cost of doing a recursive binary search and the cost of iterative search, for a data structure work. Can someone help…
asked Sergio Souza Novak 513 -
0
votes2
answers399
viewsQ: What is the Visualg extension for Github?
I have some old codes of mine in Visualg and would like to publish on Github, someone knows the Visualg extension that Github recognizes?
-
1
votes1
answer66
viewsQ: Doubt pointers in C
I have a whole number nI wish to break (separate your digits) and store in a vector, but my code does not work... what I am missing? #define TRUE 1 #define FALSE 0 #define DIM1 3 #define DIM2 3…
casked Sergio Souza Novak 513 -
8
votes3
answers1585
viewsQ: How to generate large random numbers in C++?
I’m looking to make a random number generator of [0.4], including these, only the problem is my teacher indicated that I used 4 million to generate random numbers and what value surpasses RAND_MAX ,…
-
0
votes1
answer153
viewsQ: I can’t echo objects
I’m making an object-oriented system with php and I noticed that the following code does not work: <?php include 'User.php'; $temp_user = new User();…
phpasked Sergio Souza Novak 513 -
2
votes1
answer206
viewsQ: How to autocomplete php tag in netbeans?
am a beginner in PHP and would like to know how to make netbeans autocomplete the tag <?php ?>because every time I have to write the whole tag and it’s filling me up (on Sublimetext he writes,…
-
2
votes3
answers321
viewsQ: Why give new in class attribute?
I am leaving C++ for JAVA and would like to know why to give new already in class attribute? public class ExemploPES2 { class y{ int value; } class x{ private y nova = new y(); } I do not understand…
javaasked Sergio Souza Novak 513 -
0
votes0
answers194
viewsQ: Do you doubt how to take the background when selecting a word in Netbeans?
In Netbeans I’m having a problem, when I select a word, it gets this marking with an unpleasant color. It would be beautiful if I switched to blue, as it happens when I program in Javafx, but when I…
netbeansasked Sergio Souza Novak 513 -
1
votes1
answer35
viewsQ: how to know if a class is immutable by Javadoc?
I would like to know if by how, by Javadoc know whether a class is immutable or not. There is some field in Javdoc for quick query, as I am using several classes and do not have much contact with…
javaasked Sergio Souza Novak 513 -
3
votes1
answer762
viewsQ: Why use the Observablelist?
I have a theoretical doubt. I was studying Javafx and do not know what the function of Observablelist in this case: public void start(Stage stage) { //Creating a Text object Text text = new Text();…
-
1
votes0
answers107
viewsQ: How to draw Polylines in Javafx?
How do I draw Polylines on a canvas in Javafx? I’m trying to do something similar: public void start(Stage stage) { VBox box = new VBox(); final Scene scene = new Scene(box, 300, 250);…
javafxasked Sergio Souza Novak 513 -
0
votes1
answer39
viewsQ: Can I give new in one class within another’s builder?
I have two classes: Trajectory and Trajectory. When I go new to Trajetoi inside the constructor in Trajeto the program does not compile. Someone can help me? Builder of Trajetoi: Trajetoi(string…
c++asked Sergio Souza Novak 513 -
1
votes1
answer82
viewsQ: Why are instantiated controls not displayed in the UI?
I have this login app. It is not starting the components correctly. I would like to know how to start them. The code is the same as in the Javafx book of the code house, in the login example.…
javafxasked Sergio Souza Novak 513 -
0
votes1
answer40
viewsQ: What should I do to display the return of the get class in PHP?
I have the following PHP code: <!DOCTYPE html> <html> <head> <title></title> </head> <body> <?php include '../model/class/classUser.php'; $UserNow = new…
phpasked Sergio Souza Novak 513 -
0
votes1
answer88
viewsQ: add to JAVA text file
in my code I wanted to add in the file but I’m not getting it, it always erases the content from before. package classejava; import java.io.BufferedWriter; import java.io.FileWriter; import…
javaasked Sergio Souza Novak 513 -
1
votes1
answer319
viewsQ: What is the purpose of the C++ qsort function compare function?
See below an example of application of the function qsort, using a function compare: #include <iostream> #include <cstdlib> #include <climits> using namespace std; int compare…
c++asked Sergio Souza Novak 513 -
6
votes3
answers570
viewsQ: How to jump from one tab to the other in Sublime Text?
Is there a shortcut on the keyboard to jump from one tab to another in Sublime Text?
sublime-textasked Sergio Souza Novak 513 -
0
votes1
answer62
viewsQ: Can c++ templates only be used once?
I have this code in c++ and am getting an error: #include<iostream> using namespace std; template <class T> void setVector(T* v, int sizeOfV){ for(int…
c++asked Sergio Souza Novak 513 -
0
votes1
answer821
viewsQ: how to create a block to display c++/java code in HTML/CSS?
I have a JAVA code, I would like to post it on a website. How do I do that? I’m using css spreadsheets but they "spoil the spaces" between the keys and don’t show high light JAVA code, how do I fix…
-
2
votes2
answers2074
viewsQ: Dynamic matrix allocation in C++
I would like to dynamically allocate this matrix in C++: int main() { int n,m; cin>>n>>m; if(n>m){cedula tabela[n][n];} else {cedula tabela[m][m];} return 0;} but the code does not…
-
0
votes1
answer94
viewsQ: Input formatting
I am solving a paper on the problem of transportation. Only that all my entries are delimited by a ENTER I would very much like to 1.read two integers (separated by space) 2.Give a ENTER 3.Read an…
-
4
votes4
answers398
viewsQ: Use of self-reference
About the use of self-reference thiswanted to know what difference it makes: public static class Aluno{ private String nome; public String getNome(){ return nome; } public Aluno(){ this.nome="abc";…
javaasked Sergio Souza Novak 513 -
0
votes1
answer99
viewsQ: C++ Doubt-Basic Solution Northwest Corner
I’m kind of forgotten about programming and I have a math algorithm to do, it’s the transportation problem, I’m in the northwest corner phase. My doubt is in a build error. Code:…
c++asked Sergio Souza Novak 513