Posts by ed1rac • 422 points
16 posts
-
4
votes5
answers5647
viewsA: What is the orthogonality?
In programming language, orthogonality means that a relatively small set of primitive constructions can be combined in a small number of ways to construct the control and data structures of a…
terminologyanswered ed1rac 422 -
2
votes4
answers2530
viewsA: What are Traffic Lights in Programming?
Semaphore is a special protected variable (or abstract type of data) whose function is to control access to shared resources (for example, a storage space) in a multitasking environment. Usually a…
-
3
votes2
answers9703
viewsA: Is it possible to program object oriented in C?
The closest to OO that the C language can reach is using TAD’s (Abstract Types of Data). And yes, you can "separate" the interface of an ADT implementation into separate files (in fact, ideally you…
-
0
votes2
answers99
viewsA: Array returns wrong value in java
You are not storing in the array every line you read. A proposal is to do so: public static List<String> leExibeArquivo(String arquivo) { String s, temp; // HashSet<String> valores = new…
-
1
votes1
answer189
viewsA: Administrator of Parking in C
Actually, there are several problems in your code: Does not initialize array dimension variables, such as i; Works improperly with arrays whose contents are a string (another array); Uses a…
-
0
votes3
answers59
viewsA: What am I doing wrong? (struct)
To resolve change the vector name, for example, to Books. struct book books[100]; Then when assigning the value 1 to a float do so: books[0].price = 1.0;…
-
2
votes2
answers183
viewsA: Can I use C# (through Visual Studio) to develop a program for Mac/OSX?
Yes. Visual Studio for Mac already exists. A free and complete IDE for creating modern apps for Android, iOS, and macOS, as well as web apps and cloud services. The Community version is free and…
-
0
votes2
answers2327
viewsA: Object vector in C++
For each position in the Array you must create a new object and insert it in its proper position. And to sort, choose one of the class attributes as name or age to serve as sort index.
-
0
votes1
answer81
viewsA: How can I make a log box always show the last line?
You can try a regular expression to capture the last line and display it. Try this regex: \r?\n?[^\r\n]*$
-
1
votes2
answers325
viewsA: Doubt in Complexity of Algorithms
In fact, it is not completely wrong. Everything I will write here was taken from the book and video lessons of Cormen et al (2002). To begin with, the Big-O (or O-big) notation serves only for an…
answered ed1rac 422 -
0
votes2
answers5978
viewsA: How to print binary/generic trees using C?
I found this code here in Stackoverflow. It’s still vertical, but it’s already stylized: #include <stdio.h> #define espaco 5 typedef struct no{ int valor; // valor of the no struct no…
-
7
votes2
answers170
viewsA: How do web hosting systems work?
Come on: 1: What are the types of limitations that a common hosting has (or some limitations that can be considered when making the right choice)? R = mainly monthly traffic, number of views or even…
terminologyanswered ed1rac 422 -
2
votes2
answers348
viewsQ: Match in regular expression with special REGEX symbols and line breaks
I need help with a regular expression match in a string whose: beginning and end of a line with the character } keep marrying everything you find in the next line (including other "escaped"…
-
0
votes2
answers1631
viewsA: How to install Numpy via PIP windows 7 64 bit
Also interesting is to install Python(x,y) (https://python-xy.github.io/downloads.html) which comes with all numerical libraries already installed in addition to several other important tools for…
-
1
votes2
answers5978
viewsA: How to print binary/generic trees using C?
In the book "Algorithms in C" Sedgewick has a very interesting form (and very similar to what you want to print trees (of any type, but particularized for binary trees). With small changes you put…
-
4
votes2
answers1826
viewsA: How is a program loaded into memory and then executed?
Well, basically the executable is loaded into memory by the Operating System. Actually, your question has to do with memory management and each operating system has a way to manage it. In general…