Most voted questions
150,413 questions
Sort by count of
-
3
votes4
answers58
viewsRepeat loop on id
As you can see in the code below, the only things that change is the number at the end of the id, example: (#slide_titulo1, #slide_titulo2...). I would like to know how to create a loop of…
javascriptasked 5 years, 7 months ago Nycolas 111 -
3
votes1
answer1345
viewsDouble chained list - Java
I’m trying to create (I’m learning) a doubly chained list based on an exercise, in which the list will be a train with wagons. The exercise asks to create a class "wagon", where the variables "wagon…
-
3
votes1
answer490
viewsGenerate JSON with header and detail of multiple records
I have the following tables: orcamento storing information under the heading of the budget; orcamentoItens that stores budget items; itens that stores the details of the items. (I’ll put the…
-
3
votes1
answer93
viewsNullpointerexception when saving an object
I have a save methodRegister and in this method I save the company and its address, it saves the company first, but when saving its address occurs a Nullpointerexception Entity Address Person…
-
3
votes3
answers503
viewsCombination of values for sample selection
Guys, I’m having difficulties to finish a job and would like help. Anyway, below is the excerpt from my list.csv: n,NOME,COR,VALOR 1,Lapis ,Verde,"11,1" 2,Caneta ,Vermelho,"12,25" 3,Lapiseira…
pythonasked 5 years, 7 months ago Marcelo João 33 -
3
votes1
answer1323
viewsCS0116 C# A namespace cannot directly contain members, such as fields or methods
Good afternoon, I am using VS17 C# and copied the command of another project and is giving error: CS0116 C# Um namespace não pode conter diretamente membros, como campos ou métodos error line:…
c#asked 5 years, 7 months ago Thiago Mazette 45 -
3
votes1
answer92
viewsDoubt about Python classes and attributes
I have a question about classes, attributes and objects in Python. For example using the class below: class Car: drivers = ['João', 'José'] def allowed_drivers(self): print('The list of allowed…
-
3
votes0
answers645
viewsAjax always returns HTTP error Error 404.15 - Not Found ASP.NET MVC 5
I use ASP.NET MVC 5 and developed a website, when I execute the following Ajax request: $.ajax({ method: "POST", url: "/Galeria/AddGaleriaItem", data: { ID: galeriaID , ObjectString:…
-
3
votes1
answer111
viewsSlot recognition on the screen
I would like to know how to make my app recognize the famous "Notchs" (screen slots) of mobile phones. Currently I use React Native 0.55.4 in one Windows 10 64 Bits Example of a cell phone with…
react-nativeasked 5 years, 7 months ago Guilherme Campos 31 -
3
votes1
answer111
viewsHow to allocate in contiguous memory a structure that contains 1 vector with user defined size?
I was wondering how to answer this issue and I came to the conclusion that I would need a data structure with: the size of a set a previously reported size vector It would be something like the…
-
3
votes2
answers86
viewsError saving BD change in C#
I have a certain error when making changes to some data registered in the database, picture below the error also follows the code used: private void btnSalvar_Click(object sender, EventArgs e) {…
-
3
votes1
answer294
viewsDownload zip file from a URL
Good evening, I need to download a zip file and save to a server, however, with the code I am using below, it just creates the zip file on the server; when opening it, there is no file in it and is…
-
3
votes2
answers1897
viewsDjango - Null and Blank Difference
I’m having a hard time understanding the real difference between null and blank on Django, For example: In this code, to my understanding the name field will be NOTNULL in the database, but what…
-
3
votes1
answer231
viewsDoesn’t Python3 recognize 0 as int?
The question says I need to receive user entries until a blank line is typed. After the user finishes the entry, I need to check in this entry if there are valid numbers and print them at the end of…
-
3
votes1
answer228
viewsModal does not work (synchronous AJAX)
When using this JS code, using Jquery: $(document).ready(function(){ $('.visualizar').click(function(){ $('#container').fadeIn(300); }); }); function visualizarDados(codContato){ //↓ função do ajax…
-
3
votes1
answer486
viewsIs it worth encrypting database?
Recently I’ve been having the curiosity about the utility of encrypting all fields of all tables in a database. The idea is this: Create two Crets (one in the bank and one in the application); The…
-
3
votes1
answer120
viewsSearch for array containing string and number
Hello, I have an array with the following extrusion ddd: [ 'SP', 11, 12, 13, 14, 15, 16, 17, 18, 19, 'RJ', 21, 22, 24, 'ES', 27, 28, 'MG', 31, 32, 33, 34, 35, 37, 38, 'PR', 41, 42, 43, 44, 45, 46,…
-
3
votes1
answer79
viewsIs it correct to make a user authentication by the backend return message?
Good afternoon, you guys! Earlier I took a question regarding user authentication in my application and after some good tips I was able to authenticate my user, the doubt now is whether the method…
-
3
votes2
answers245
viewsDoubts in the modeling of the Database
Guys, I have the Product, Ingredient and Sale table. The product contains several ingredients, e.g.: Suppose that the product is a mixture, it contains 1 bread and 2 Ingredient cheeses, this…
-
3
votes3
answers1436
viewsSQL - Two different WHERE conditions for the same SELECT
I am developing an SQL query which has two different WHERE functions according to the return of a variable. I tried some alternatives but none seem to fit, I need something with this logic: IF…
-
3
votes1
answer159
viewsSelecting logistic regression variables
I’m new to RStudio and I’m having trouble simplifying my code. I’m doing a logistic regression and would like to select only variables with p<0.20. For that, I did the following: imcbi <-…
rasked 5 years, 7 months ago Sergio Martins Pereira 31 -
3
votes1
answer512
viewsSerialize composite object into a single json
With Newtonsoft.Json, to the next object: public class Person { public string Name { get; set; } public string GeneralText { get; set; } public Address Address { get; set; } } public class Address {…
-
3
votes1
answer164
viewsAbout the behavior of userland functions and internal functions in PHP
There is a proposal to unify the behavior of userland and internal functions in the PHP 8. That currently in particular, when internal functions fail to parse argument types correctly, they fail to…
-
3
votes2
answers487
viewsClosing a loop, with enter
I’m looking to close one while True: pressing a key, in case simply pressing enter without writing anything. while True: key = input("Press enter") if key == " ": break else: #loop How can I do it?…
-
3
votes1
answer86
viewsHow to make the output of the Kable() command appear in Rstudio Viewer?
I’m trying to get a Latex table with the knitr package R, but I’m not getting the output to appear on Rstudio Viewer. For example, when trying to convert head(mtcars): kable(mtcars, "latex") I get…
-
3
votes0
answers45
viewsBehavior of Math.Round
I have a project in VB.Net that I use the Round Function, but see the strange behavior: System.Console.WriteLine(math.round(32.625,2)) '32.62 System.Console.WriteLine(math.round(32.635,2)) '32.64…
-
3
votes1
answer126
viewsPerformance according to box control modeling
I am making a system for daily box control, which allows launches/deletion of values. Below is the table that will store the values, filled with some data to exemplify. There are more fields, but…
-
3
votes1
answer775
viewsDoubt about Chomsky’s hierarchy
Regarding the 4 types of languages, I doubt to understand about context-dependent or context-sensitive language. I find very confusing the explanation that I find through the sites, I would like…
-
3
votes2
answers334
viewsPerform a DELETE with Where being the result of a SELECT (MYSQL)
Guys, have a code in which I use the result of a SELECT to be a condition in the WHERE of a DELETE. I’ll leave the code part to see if you can spot any errors. UPDATE (which is at the top of the…
-
3
votes3
answers52
viewsDoes code always return the last character?
I have the following code var browserType = 'mozillad'; var browserType2 = browserType[browserType.length-1]; document.write(browserType2); Because he returns d it is returning the last character…
javascriptasked 5 years, 7 months ago user139915 -
3
votes1
answer123
viewsEquivalence to kmeans inside Caret::Train
I tried to adjust a model kmeans within the package caret with the function train. But I checked that it is not available. I generated a frame to do this: set.seed(15) d <- data.frame( x =…
-
3
votes2
answers74
viewsRenaming string text in a column
Hello, good morning! I have a quarterly data frame that is divided by 1st, 2nd and 3rd month of each quarter, see: Trimestre Variável Referência temporal 1º trimestre 2007 Animais abatidos No 1º mês…
rasked 5 years, 7 months ago Ingled M Cardoso 159 -
3
votes4
answers361
viewsPython Code - Conditional Structure
As I do in Python to receive the value of the base salary and the sales value of this seller, the employee’s basic salary should be up to R $ 700.00 with a 4.5% bonus on their sales and if the sales…
-
3
votes1
answer328
viewsHow to get all keynames within localStorage
How to catch all the keyNames (not the values) within localStorage and add as option in one element select? Code in operation here Explaining the code: 1. The function salvar() saves a key with the…
javascriptasked 5 years, 7 months ago Mark 169 -
3
votes1
answer302
viewsImport chatterbot bot to Telegram
I don’t know if that kind of question is welcome here, but come on: I’m developing a chatbot on python and chose the library chatterbot because of the processamento de linguagem natural, by the…
-
3
votes0
answers169
viewsHow to change the title, caption, filter and export the Map in pdf using leaflet in R?
I created a map of MG to identify the Qtde of consultations by mining municipality. I got the code below on the internet and it worked. But I would like to add some more information, but I’m not…
-
3
votes3
answers1730
viewsChange date format from "yyyy-mm-dd" to "dd/mm/yyyy"
I’m trying to change the shape of a date yyyy-mm-dd for dd/mm/yyyy. I’m using this code: $date = "2019-03-27"; $date1 = new DateTime(date_create_from_format('Y-m-d', $date)->format('d/m/Y'));…
-
3
votes1
answer1355
viewsPassword or invalid user when logging into oracle database (ORA-01017)
Good morning, everyone, I need to set up an environment for a course. For this I installed the Oracle database and SQL Developer. In the oracle database I have the SYS user working perfectly. The…
-
3
votes2
answers82
viewsSave changes to the bank
I am trying to change the data saved in the Database, basically when I double click on DataGrid he populates my TextBoxs to make the changes in the bank, but when I click to save it from the…
-
3
votes4
answers1772
viewsError installing xlsx package
I need to write files that are in xlsx format, a package option that does this is xlsx, but when I went to install it appeared the following error: require(xlsx) Carregando pacotes exigidos: xlsx…
rasked 5 years, 7 months ago Pesquisador008 59 -
3
votes2
answers117
viewsI could not resolve the error: The condition has length > 1 and only the first element will be used
I know there are other questions about this mistake, but since I’m a beginner they didn’t help me solve my specific problem. I am working on the following date.frame: structure(list(Dates =…
-
3
votes2
answers319
viewsHow to scroll through an enumerable list and check if the property repeats in the list during foreach turns
I have a list (IEnumerable) called People that contains the properties Id, Datanasc, etc... I need to bring this data to a listview in the html using the Razor (or it can be outside the cshtml page,…
-
3
votes2
answers92
viewsHow does React dependency/library management work?
Hey, you guys How does React dependency/library management work? Do you have a page in the documentation that talks about? Importing a library that has, for the most part, things that I won’t use…
reactasked 5 years, 7 months ago Joaldino Neto 31 -
3
votes1
answer59
viewsDelete characters from a string
Hello, I have the following code snippet: agenciaModel.Bcx_Nome = agenciaViewModel.Bcx_Nome; to agenciaModel is sent to the api and sent to the banco de dados, but in the database the maximum string…
c#asked 5 years, 7 months ago Jeff Henrique 1,020 -
3
votes1
answer302
viewsC# and Entity Framework with Foreignkey between classes
People in my projects .Net MVC use the structure below. My projects, are with Entity Framework. The briefcase Entidades, are the classes I use in DbContext. Detailing the problem I have the class…
-
3
votes1
answer213
viewsTake specific position in . each
I made a noose .each that returns some button: $(document).ready(function(){ listarPedidos() var consultas = setInterval(listarPedidos, 4000); }); function listarPedidos(){…
-
3
votes1
answer108
viewsIs there any way to hide Ajax in a web application?
Is there any way to hide AJAX in a web application? To what extent is AJAX safe? Because analyzing the code you can know the address of the server, the file, the function, and even the response of…
-
3
votes2
answers69
viewsI need to know where in that code is my mistake - MATRIX C
In the letter i was to give 9,2 but the result that shows is 9,50. How to find out which class has the most homogeneity in relation to grades? float turma1[4][5] ={ {8.2,9.2,8.7,6.0,7.0},…
-
3
votes4
answers249
views -
3
votes0
answers240
viewsWhat am I doing wrong?
Hello, good(a) day, afternoon or night, I would like you to help me answer what I am doing wrong in my code, because, I have already tried to redo and do everything and more, and I am not…