Most voted questions
150,413 questions
Sort by count of
-
32
votes3
answers13710
viewsWhat is a Polyfill?
I’ve seen that term Polyfill being used several times when it comes to a new function that is not available in older versions of certain languages and the like. But after all, Polyfill is simply…
-
32
votes1
answer3647
viewsWhat is shadow DOM?
When I was reading about some Javascript frameworks, for example the React, I read the expression a few times shadow gift in some articles. It even seems that it is possible, in Chrome console…
-
32
votes4
answers8677
viewsWhat’s the difference between data and information?
According to this definition of Datum: Data is a set of information (quantitative, qualitative, categorical or indefinite) can be organized or not. Wikipedia. Following this line I can assume that…
terminologyasked 8 years, 5 months ago gato 22,329 -
32
votes5
answers10820
viewsHow to Reverse a String?
A user will enter a sentence and I must display this inverted sentence in upper case. How can I do this? import javax.swing.JOptionPane; public class ExerLar01 { public static void main(String…
-
32
votes2
answers55629
viewsCORS - No 'Access-Control-Allow-Origin' header is present on the requested Resource
Good evening, I’m trying to access a server from my local machine and I’m getting this answer: No 'Access-Control-Allow-Origin' header is present on the requested Resource. Origin 'http://localhost'…
-
32
votes2
answers1853
viewsWhat is agent-oriented programming?
We have some well-known programming paradigms, but I faced this paradigm and I had some doubts: Where it is applied? Is there any example of where it has been used successfully? What is the…
paradigmsasked 9 years, 5 months ago Wellington Avelino 2,844 -
32
votes2
answers1620
viewsWhen to use icon, or text, or more text icon?
It is common to see, in software for any platform, some places where the user can select an option and to identify there what is this option there may be an icon, or there may be a short text, or we…
-
32
votes1
answer512
viewsArduino I2C sends unexpected NACK
I’m wearing a Development board of microchip (explorer 16) with the pic24f128ga010 as Master and the Arduino as Slave. The PIC is sending everything right, but for some reason NACK for all the date,…
-
32
votes2
answers2760
viewsWhat is a memoization?
What is memoization? Under what circumstances can it be useful and how can it be used? (If possible, illustrate with a simple example)
-
32
votes4
answers5405
viewsStrategies to analyze very large databases in R (that do not fit in RAM)
Suppose I have a huge database that doesn’t fit in RAM. What strategies to analyze this database in R, since I cannot load it entirely into memory? PS: The question isn’t just about how to get R to…
-
32
votes1
answer7672
viewsHow does asynchronous programming work in Javascript?
As far as I know, asynchronous programming in C#, for example, uses the idea of threads. The tasks to be performed can be divided into threads and then run in parallel. I always imagined that…
-
32
votes2
answers6682
viewsWhat would be the way to validate the CPF checker digits in a DB using only a SELECT?
Finding information on how to calculate the CPF check digits is not difficult. Any Google search gives numerous results. Most are reliable and even have a well respected source which is the entry on…
-
32
votes5
answers1927
viewsWhy is multiplication faster than division?
Bit brushing question, but I was reading an article about javascript in which says that division is slower than multiplications. And for example, I would recommend changing the code below : var…
javascript mathematics performance optimizing characteristic-languageasked 10 years, 10 months ago Guilherme de Jesus Santos 6,566 -
32
votes5
answers41630
viewsMysql Limit Equivalent in SQL Server
Someone knows how to relate the differences between Mysql and SQL Server, including using LIMIT n,n? Or if you have a link that lists the differences would be nice. Example SELECT * FROM tabela…
-
32
votes2
answers1436
viewsWhat it means '~' in front of the constructor of a C#class
Working on a project here at the company, I came across some commands that are now being used more (yield, ??, anonymous type) but until I understood, but one who called my attention by not knowing…
-
32
votes5
answers32771
viewsHow to calculate the age of a person with JS, from the date of birth?
How can I calculate a person’s age in Javascript from the date of birth? I tried something like: function idade(dia, mes, ano) { return new Date().getFullYear() - ano; } idade(11, 12, 1980); // 33…
javascriptasked 10 years, 11 months ago Cabeção 1,799 -
32
votes6
answers98339
viewsHow do I undo the last commit in Git?
I accidentally committed the wrong files to Git. How to undo this?
-
32
votes5
answers5370
viewsHow to apply ! CSS import via jQuery?
I’m trying to apply style to my element and define its importance in this way: $('div').css('height','50px!important'); But it doesn’t work, which would be the right way?…
-
32
votes7
answers58283
viewsRegular expression for e-mail validation
I am trying to create a regular expression to validate any e-mail, I wrote the expression below, but it is not working as expected: var parse_email = /^[a-z0-9.]+@[a-z0-9]+\.[a-z]+\.([a-z]+)?$/i;…
-
31
votes2
answers1150
viewsWhat is a microfrontend?
I have come across several "new" terms over the internet when it comes to programming. And recently, I came across the term microfrontendon. From what little I could understand, the idea would be…
terminologyasked 5 years, 4 months ago Wallace Maxters 102,340 -
31
votes2
answers930
viewsWhat is a meta language?
I found in the SO En that question: Creating meta language with Java, where the user is interested in creating a meta language using Java. I did a brief search and found on the Microsoft site a…
-
31
votes2
answers1602
viewsWhat is Inter Process Communication (IPC)?
In a discussion with experienced programmers here on the site regarding competition control, the terms arose traffic lights, mutex, shared memory, monitor, and still others, which I’m beginning to…
-
31
votes1
answer1866
viewsWhat is the Webassembly?
Reading random articles, I read one that predicted the end of Javascript through Webassembly, which seems to be a way to get other languages to do Javascript’s work, but I’m sure this is a wrong…
-
31
votes5
answers12535
viewsWhy is Varchar(255) widely used?
Why in various databases, say to set the size as varchar(255)? For example, in a field email why put varchar(255)? It would not be better (in question of storage and processing speed) to put…
-
31
votes2
answers5048
viewsWhat is a context-free language?
In Wikipedia has the following statement: In formal language theory, a context-free language (LLC) is a language generated by some context-free grammar (GLC). Different context-free grammars can…
-
31
votes4
answers6983
viewsDelete thousands of records from a table
I have a table, for example, pessoa, and would like to delete all people over 40, with the script below do it: DELETE FROM pessoa WHERE pessoa.idade > 40; The problem there is more than 2 million…
-
31
votes2
answers843
viewsIs it really necessary to put "text/javascript" in the <script> tag?
We are in 2016. I have read in some places on the internet that it is no longer necessary to use this statement type="text/javascript". In fact, use the tag script without declaring this excerpt…
-
31
votes3
answers1336
viewsIs it ideal to use primitive types in Java?
Java has several wrapper’s who help us (Integer, Double, BigDecimal), and also gives us the possibility to use primitive types (int, float, char). A teacher told my college class that Java should…
-
31
votes3
answers13759
viewsDifference between %i and %d
Is there any difference between printf("%d", x); and printf("%i", x);? I know the two return the same result, have some kind of convention adopted to always use the %d?…
-
31
votes6
answers7015
viewsHow to get unique values in a Javascript array?
In PHP, when I have one array with duplicated values, it is possible to obtain only unique values through the function array_unique. Example: $array = ['a', 'b', 'b', 'c', 'c'];…
-
31
votes2
answers7772
viewsWhat characterizes imperative and functional programming?
What characterizes the imperative and functional programming and what are the differences between them in relation to each other? I cannot understand these two paradigms. Note: If you can cite…
javascript terminology functional-programming imperative-programmingasked 8 years, 9 months ago gato 22,329 -
31
votes1
answer5828
viewsDifference between Task and Thread
I need to create an executable c# and the question was: Do with thread or do with task? In practice there is some difference between using Task and the "traditional" multi-thread?? It is true that a…
-
31
votes1
answer5487
viewsWhat is the difference between single quote ' and double quote " in SQL?
Context When I do an SQL and wish for a specific alias I should quote between double quotes ". SELECT A.ds_nome_pessoa AS "Pessoa.nome" ... When I want to make a where in field varchar the values…
-
31
votes3
answers1472
viewsHow does an SQL Injection happen?
Why creating parameters for each field that will be updated helps prevent SQL Injection? Example: SqlCommand comm = new SqlCommand("UPDATE Contatos Set Telefone = @Telefone, " + "Cidade = @Cidade, "…
-
31
votes3
answers1005
viewsHow to convert animation in Canvas/JS to SVG?
I’ve been using a javascript library to make icones/symbols of a weather app. I now wanted to do in SVG the symbol of the cloud (cloudy sky), and wonder what the best approach. I made a svg with the…
-
31
votes4
answers52318
viewsWhat is the difference between PUT and POST?
Some teach that POST is to send data to create something and that PUT is to update, but found poorly explained. So, after all, what is the difference between the PUT method and the POST? When I must…
-
31
votes2
answers957
viewsHow to test software well?
Well, I was thinking how sites with great access users do tests on their software and test them for final release, why anything or error of code can lead to gross system failure is interruption at a…
-
31
votes3
answers21968
viewsWhat is the purpose of the Serializable interface?
Example of implementation: public class MyClass implements Serializable{ private static final long serialVersionUID = 1L; }
-
31
votes6
answers3667
viewsAre there objective advantages to a language being "case sensitive" or not?
Or is this just taste? I don’t want to if you like one more than the other. I don’t care why people like one or the other. I don’t want any bad answers. I don’t want to know historical reasons. I…
encoding-style language-design case-insensitive cash-sensitivityasked 9 years, 6 months ago Maniero 444,682 -
31
votes3
answers97159
viewsHow do I delete a local and remote Git branch(branch)?
I want to delete a local branch and in my remote project on Github.
-
31
votes2
answers5413
viewsWork with Session without cookies to prevent session theft
When the session is started, it creates a cookie with PHPSESSID, making the ID public. Knowing that to prevent session hijacking it is best to hide the session ID from other users, then PHPSESSID…
-
31
votes5
answers680
viewsWhat to do when a UI element cannot be used by a user?
It is common for a user not to be able to use all the elements of the interface. This can occur permanently (or semi-permanent, since some configuration or change of permission can change this) or…
-
31
votes2
answers1064
viewsWhen to use Graceful Degradation and when to use Progressive Enhancement?
When creating a website or web application, there is always the problem of what to do when not all browsers implement all desirable features. From what I’ve read, there are two main ways to deal…
web-application software-architecture ux cross-browserasked 10 years, 5 months ago mgibsonbr 80,631 -
31
votes3
answers25678
viewsWhat is a Java Bean and what is it for?
I’m starting to read about development java layered, and read something about the bean, an encapsulated class. But I couldn’t find any content that would really explain the purpose and an example.…
-
31
votes1
answer8090
viewsInternationalization using ASP.Net MVC
How can I implement an internationalization system using Microsoft’s MVC technology? Is there something similar to Android so that my website can support several languages? Is there also some way to…
-
31
votes6
answers7191
viewsHow to put default (default) arguments in a Javascript function?
In R this would be very simple: funcao <- function(x=10) return(x) If you call funcao() without arguments the result will be 10. How to do the same in Javascript? And how to know if there are…
-
31
votes2
answers1282
viewsWhat does <<< EOH in PHP do?
I see it in several third-party classes. Remembering that the closure is usually the EOH, but without <<<
-
31
votes3
answers4357
viewsDifference between Date, sql. Date and Calendar
What is the difference between the classes java.util.Date, java.sql.Date and java.util.Calendar and in which situations the use of one or the other is recommended?…
-
31
votes5
answers3608
viewsCan the browser "remember" a password programmatically?
I am developing an application where from a password provided by the user a pair of keys (authentication and encryption) is derived. The password itself is never sent to the server, only the…
-
31
votes5
answers14927
viewsHow to not allow a character to be typed in the textbox, with Javascript/jQuery?
I have a Textbox: <input type="text" name="indice" class="number"> I wanted that when a person typed a comma in this Textbox it would be blocked and not appear in the Textbox. How to do it the…