Most voted questions
150,413 questions
Sort by count of
-
17
votes3
answers31700
viewsExactly how Javascript works
I wanted to know how it works exactly, where it is necessary to use within some scope as if etc.
javascriptasked 10 years, 11 months ago filipelinhares 2,417 -
17
votes3
answers1400
viewsWhat are the ways to apply Eval in Javascript
There is more than one way to make one eval() in javascript, problem is that it can be a danger for the user if misused. Internally some other methods also do Val, for example the setTimeout() which…
-
17
votes3
answers3943
viewsAlternatives to MVC for web applications
Context (TL; DR) When we talk about architectural design patterns, we usually talk about MVC. For the web, we usually use something like the following image: So much so that much of the frameworks…
-
17
votes4
answers8554
viewsHow do LTRIM() and RTRIM() in Java?
I need to process some strings in Java. I know the method exists trim(), but I need a Left Trim and of a Right Trim. How do I do this? For now I’m walking the string with a loop and removing all…
-
17
votes3
answers72494
viewsHow can I check if one string contains another in Javascript?
I would like to check if one string contains another, as if it were a method String.contains() but apparently there is no method to do this. Does anyone know a similar method that does the same…
-
17
votes1
answer23130
viewsHow to pass a function as parameter in C?
I wanted to know how the function passed by parameter as it happens in pthread_create (thread,atributo,rotina,argumento);. On the field rotina a function is placed in void*.…
-
17
votes2
answers1365
viewsShould I use a parser generator or should I develop my own code to do "parse" and "lex"?
Obviously the question should not be interpreted "to the letter". I do not want anyone to decide for me, I need to know the perks and disadvantages to use one method or the other. When should I wear…
-
17
votes4
answers2589
viewsIs it possible to create an 'abstract class' in Javascript?
When creating a Javascript class whose attributes and methods are all static (for example, for storing preset settings for a game), I wonder if it is possible to define the class as abstract in a…
-
17
votes3
answers506
viewsHow to instantiate a Gridview or a Listview for the same Activity?
In my app I am presenting a list of items. I would like in certain situations to be presented with a ListView and others like GridView. Situations are: Smartphone(Portrait) - ListView…
-
17
votes3
answers3083
viewsHow to do a search ignoring Python accent?
Suppose I have a list of words, in Python (if necessary, already ordered according to the rules of collation): palavras = [ u"acentuacao", u"divagacão", u"programaçao", u"taxação", ] Notice I didn’t…
-
17
votes2
answers1662
viewsIn HTML5, should null elements be closed with ">" or "/>"?
In HTML 5, there is a series of null elements, which according to the specification (English) and examples given (English) by W3C, they are closed using only >: Elementos Nulos area, base, br,…
-
17
votes3
answers1314
viewsHow to get around bad rendering of a font in Internet Explorer?
I’m using a font-kit generated on Font Squirrel and am getting different results on Mac OS X and Windows environment. Would there be some way around the bad or different rendering of the Internet…
-
17
votes5
answers2401
viewsHow do I merge two results of a query?
I am developing an application in C# and I would like to know how to put together two results of two darlings SQL in one. I have the following code: public List<MalaDireta> ObterMalaDireta() {…
-
16
votes2
answers437
viewsWhat is the difference between using @Transient and Transient in an attribute of a JPA entity?
Studying some third-party codes, I came across different ways to define that a particular attribute of an Entity will not be related to a column in the database. Among the shapes I found, the first…
-
16
votes2
answers303
viewsWhat are computed names ("dynamic" structuring) in Javascript?
Reading the documentation of dismantling in Javascript, I found the section below: Computed object property and destructuring names Computed property names, as in literal objects, can be used with…
-
16
votes1
answer3610
viewsWhat exactly is the backslash ( ) for in Python?
I sent an application to Github written in Python that was updated by someone who claimed to have formatted the code properly. After starting to see the changes, I got scared thinking that it had…
-
16
votes3
answers246
viewsWhat is a modal?
I started to maintain a project that is not mine, in ASP.NET and C#. but I believe that it serves other languages as well. In some actions of buttons appears this term "modal" and I am in doubt of…
-
16
votes1
answer250
viewsDifference between the greedy ?? and *quantifiers?
I have these strings: x <- c('ondasffasf', 'ondassn\nlld', 'ondas', 'ond', 'ndasss', 'das') And this code with ??: library(stringr) str_extract(x, regex('ondas??')) [1] "onda" "onda" "onda" NA NA…
-
16
votes4
answers634
viewsWhat is the difference between i += 2 and i = i + 2?
I was seeing, there are people who speak that is different and there are those who speak that is the same thing. I am confused. They are different or do the same thing?
-
16
votes2
answers8360
viewsWhat do GMT and UTC stand for?
I recently discovered Unix Timestamp and I came across the acronyms GMT and UTC, I would like to know what they mean. I’ve already done some research, but I didn’t find anything very clear.
-
16
votes2
answers829
viewsWhat is Svelte JS?
Nowadays, much is said about the web Components and custom Elements, and along with big names like Angular, React, Vue and Polymer, I recently heard the name Svelte JS. What is Svelte JS? It is…
-
16
votes2
answers596
viewsWhy is there such a difference in performance between stream and normal loops?
I was reading a article related to the performance of streams/loops, and was startled by the difference in performance between the use of loops for large quantities of data. I decided to perform a…
-
16
votes2
answers1087
viewsHow do I identify if a link was opened by an iframe in a new tab?
How to identify if any link originated from a iframe that I do not have access was opened in a new guide? I tried with document.getElementById("i").addEventListener("click", a);, but from what I…
javascriptasked 5 years, 11 months ago Mark Vaaz 966 -
16
votes3
answers419
viewsWhat are evolutionary algorithms?
Researching on Evolutionary Programming, I came across the question What are genetic algorithms? In an excerpt from the answer: ... Genetic algorithms are a particular class of algorithms evolutive…
-
16
votes4
answers276
viewsWhy is object orientation not suitable for most scenarios?
Citation maniero: It’s the biggest problem we have in our area, and it’s getting worse: something very good is created and it serves 1% of the problems, maybe 10%, but people want to use it for 100%…
-
16
votes2
answers11240
viewsDifference between splice() and Slice()
What is the difference between the functions splice() and slice() of the object Array of JavaScript and when each shall be used?
-
16
votes3
answers4406
viewsUse @media, @media screen and or @media only screen and Have a difference?
I was wondering if there is any difference in css when using one of these media queries, Example A: @media(max-width:770px) { .texto{ color:red } } Example B: @media screen and (max-width: 770px) {…
-
16
votes2
answers319
viewsHow do CSS ignore if the attribute is capitalized or lowercase?
Imagine I have a situation where I need to style multiple links from my page, but only the links that end in .html, but I noticed that when trying to get the attribute href, I can only catch the…
-
16
votes2
answers1660
viewsWhat is a Backend as a Service (Baas)
I would like an explanation of what a Baas is that would overcome some doubts: What is Baas? In general, they are an API and/or framework and/or library? Why? What are the main ones? What are the…
-
16
votes1
answer4985
viewsWhat is it and what is Odata for?
I’ve been getting a few people talking about OData, I did some research I saw some codes, but I didn’t understand some things, among them: What good is Odata? What are the advantages and…
-
16
votes2
answers301
viewsWhat is serverless architecture?
Could someone briefly explain what a Serverless architecture is? After reading a few pages here, I was in doubt. Of Wikipedia, basically sums up what’s out there: [...] A cloud computing Execution…
-
16
votes3
answers2012
viewsWhy does Scanner return error on something that is within the expected?
Note that I have typed a number, a text and a number, as you ask there. import java.util.Scanner; class Ideone { public static void main (String[] args) { Scanner entrada = new Scanner(System.in);…
-
16
votes4
answers1634
viewsWhat does the term "atomic" mean?
I see in some answers/questions the term "atomic". In programming, what it must mean in fact? Ex: comparison (4) is possible only for Atomic and list types What are the atomic transaction methods in…
-
16
votes1
answer413
viewsHow does "positive" (?=X) work combined with "positive" lookbehind (?<=X)?
After answering this question, and despite can understand what is happening in the regular expression of my reply, I was curious to know how the excerpt ((?<=;)|(?=;)) works. I read in this reply…
regexasked 7 years, 3 months ago user28595 -
16
votes2
answers11683
viewsWhat is the difference between Arrays.asList and List.of?
Studying Java 9, I saw a new method that works with collections: List.of, example: List<String> frutas = List.of("maça", "laranja"); I’ve used it before Arrays.asList, example:…
-
16
votes5
answers19971
viewsValidate regular expression name and surname
I need to create a regular expression that validates whether the format of the user’s name and surname is valid, for example: Maria Silva | true Maria Silva | false Maria silva | false maria Silva |…
-
16
votes2
answers1206
viewsShould placeholders contain examples or descriptions?
I am building an application and in my forms the placeholders fields are empty because I haven’t decided which criteria to use to fill them. On many websites and apps it is common to find two types…
-
16
votes3
answers582
viewsMaven Module vs Java 9 Module
Besides the fact that Maven works with jars and Java 9 with "modules", what is the difference between the modularization system of the two? Why would I stop modularizing my systems with Maven to…
-
16
votes2
answers2789
viewsIs SOA the same as REST?
I am learning about SOA in a college course. And from what I understand, SOA is tied to the concept of Web Services. There are also REST Apis that are also related to this concept. Both terms give…
-
16
votes4
answers4728
viewsHow to write values to the Mysql database using PHP?
I have a database that I created in MYSQL with the table called publicacoes. This table has the fields id, titulo, conteudo and data_publicacao. I would like to know how to insert values in this…
-
16
votes11
answers38715
viewsHow to check if the variable string value is number?
I am developing a program where the user type a data, then I have to check if the value is number to proceed with the operation, but if he type a non-numeric value he is alerted about the invalid…
-
16
votes1
answer2540
viewsWhat is the difference between Javajdk and Openjdk?
I have been researching and from what I have seen both are kept Oracle skin... But if java is also open source, what is the need of Openjdk? Or I’m wrong about Java if open source?
javaasked 7 years, 8 months ago Marcos Rai Alves da Cunha 372 -
16
votes2
answers590
viewsWhat does Iot mean in the context of development?
Today only talk about Internet of Things. I understand that this is the use of the Internet in various devices. The idea is that any object can connect to the internet and benefit from this.…
-
16
votes3
answers3624
viewsWhen to use asynchronous or synchronous method?
When to use asynchronous or synchronous methods in controllers (index, search, delete, create) of ASP.NET MVC applications? Can I lose performance? In which situations should I use one or the other,…
c# asp.net-mvc .net entity-framework asynchronousasked 7 years, 9 months ago George Wurthmann 4,415 -
16
votes1
answer880
viewsHow do >, + , ~ selectors work in CSS?
Selector + Takes the first element found after your declaration. div + p { font-size: 20px; } <div> </div> <p>Este é um paragrafo</p> <p>Este é outro…
-
16
votes6
answers12128
viewsError typing GIT PUSH
I’m on my machine and want to upload the files on my local machine to my repository on github with.. I’ve already executed the commands git add, git commit and all that remains is to raise them.…
-
16
votes3
answers1408
viewsWhat are the differences between the forms of dependency injection?
Considering the injection of dependencies into Angularjs, there are some ways to do it. The modes as far as I know are: Form 1: angular .module('meuModulo', []) .controller('MeuController',…
-
16
votes1
answer669
viewsFree SSL certificates Let’s Encrypt has the same reliability as paid?
Encryption TLS is the one used by lets encrypt and uses the protocol acme that makes the file exchange between server - client, I realize that when using https websites get a small delay I have…
-
16
votes2
answers418
viewsHow does a Java Virtual Machine written in Java work?
Seeing the Jikes RVM I was curious to know how this works (in theory), but only found material in English. I am correct in assuming that the JVM today is done in C/C++, which in turn is done in…
-
16
votes1
answer1890
viewsWhat is __all__ in Python for?
I’ve seen some code written in Python whose file __init__.py had a variable __all__ with a list assigned. Example: __all__ = ['foo', 'bar'] I’ve noticed that in Python, when things start with…
pythonasked 8 years ago Wallace Maxters 102,340