Most voted "comparison" questions
Used to compare different types (compare variables, objects, files, etc).
Learn more…155 questions
Sort by count of
-
0
votes1
answer154
viewsWhat Method to Send Email in Python?
for row in values: # Separei os valores da data em 3 variaveis temp. year = int(row[0][6:10]) moth = int(row[0][0:2]) day = int(row[0][3:5]) if day == d1.day and moth == d1.month and year ==…
-
0
votes0
answers179
viewsCompare values of a multidimensional array in php
I have the following array I need to generate confrontations between them aletorios and the teams of the same array Ex. Santos and São Paulo cannot face each other!! array(5) { [1]=> array(2) {…
-
0
votes0
answers44
viewsFind char in a string, never find
I made a function search for a character in a string. The input parameters are the string and the character. The function returns 1 (one) if the character exists in the string or zero otherwise. The…
-
0
votes1
answer71
viewsCompare device phone numbers with a database
Hello! I am developing an app and need to buy the phone numbers of the device with a list of phones in a database, but the phone numbers can be written in different ways as described in Wikipedia:…
-
0
votes1
answer205
viewsMore efficient way to compare two variables type List
I have two variables of the type List that need to be compared to each other to verify possible duplicates. Example of Variable Contents Variable 01: [01, Test, Active] Variable 02: [01, Test,…
-
0
votes2
answers2415
viewsSQL query that compares two tables and returns values
Work with a database using with DBMS Postgresql, where I need to compare tables, example: table_janeiro and table_February. I need to perform two consultations... first You must return the values…
-
0
votes3
answers1276
viewscode to return divisors and compare common ones
I am trying to create a code that returns the common divisors between 2 variables that receive integer numbers. And then show the common divisors. To return me the splitters I am using this code for…
-
0
votes1
answer912
viewsComparison of an image with others (analyze whether the chosen image is the same as the others already predefined or not)
I’m trying to make a code in Java that compares an input image with other n images already defined in the code. I developed, with (quite) help, a similar code, which compared two images only, the…
-
0
votes1
answer340
viewsHow to compare two Oracle Datetime columns
I have a column where I enter a date when the event happens (local storage), and the date when the event is sent to my system. The difference between the date of the event and the date of dispatch…
-
0
votes2
answers84
viewsValidation of 2 fields in a table
I have a table in Mysql, with a DESCRIPTION field and another Degree, as I do so that the set of the two fields cannot be repeated? EXAMPLE If it is: DESCRIPTION: abcde GRAU: 12345 OK And if it is:…
-
0
votes1
answer31
viewsphp method that checks two strings in a variable
Does anyone know any method in PHP that matches the value of a variable with string? I need to refactor the following code: public function hasPlan() : bool { return $this->reference === 'unico'…
-
0
votes2
answers99
viewsHow to compare email and word passes from textboxs to the database
I already have this code: <?php ... $dbconn = mysqli_connect($servername, $username, $password, $dbname)or die("Failed to connect to database:" . mysqli_error($conn)); $email =…
-
0
votes2
answers99
viewsdoubt string/map c++
Good afternoon! I’m answering a programming list, the question is very easy and I know the logic of execution but there is a part that I do not know how to implement, I left it in italic. Make a…
-
0
votes1
answer3094
views"Warning comparison between Pointer and integer" - what is it?
during the compilation of the code in C language I appeared this error: [Warning] comparison between Pointer and integer for this step of the code: if(livro > TAM) { printf("------- Você já…
-
0
votes1
answer61
viewsAn alternative to Strings?
Several things in the project have a table with possible names (strings). But I don’t want to use strings to make comparisons for various reasons (case-sensitive, typo, name table changes, etc). So…
-
0
votes2
answers249
viewsComparison of strpos() variables - PHP
I need some help between levels of access, I’ll post some of the code. It is a connection in AD (Active Diretory), authenticating the user and searching to which group he belongs. This is the login…
-
0
votes1
answer260
viewsFalse return when comparing two python identical strings
I’m trying to compare two strings, one comes from the database as an array, the other is written by hand: string = str(profile[1]) #Carlos Gimenes print(string == str('Carlos Gimenes')) #Retorna…
-
0
votes3
answers211
viewsCompare the widget with the rest of the Python list
I need to create a program where in the given list, if the name is repeated it puts a numbering. For example: names = [maria, Joao, maria] the result should be result = [maria, Joao, maria1] Other…
-
0
votes1
answer578
viewsCompare two object arrays?
I need to compare 2 arrays in Javascript, one that returns from a Mongodb query and the other comes from the email provider. The two comparison criteria are the email ID and the box to which it…
-
0
votes0
answers74
viewsIs it possible to change a comparison of an existing variable in Matlab?
You can change/change the equality (comparison) of an existing variable in Matlab?. The variable eq of my program has as value the first highlight below. This variable is compared to 0. I want to…
-
0
votes1
answer727
viewsList of attributes with differences between objects - Java
I need to compare two objects in JAVA so I can get a MAP with key and value of the attributes that present difference. I need this logic for a generic object, capable of receiving any type. Ex:…
-
0
votes1
answer297
viewsString check inside a C function
Greetings! I’m creating a C program where the user can change the state of some sensor by typing the sensor name and 1 or 0 to change the state of the sensor, being 1 for on and 0 for off. However,…
-
0
votes2
answers72
viewsTwo identical arrays returning false when compared
I need help with this code that doesn’t seem to make sense. I have debugged and the values given up to the penultimate line are: splited = ["i","s","o","g","r","a","m"] unique =…
-
0
votes0
answers14
viewsDoubt - List of dependencies that do not exist in the repository
Good afternoon, I wonder if there is a Maven command that parses pom.xml and tells all the dependencies that are in the pom.xml file and are not in the repository. I even found a command mvn…
-
0
votes0
answers26
viewsError compareTo Key
Save people, I have the following problem, I am implementing a code that returns me the median of a sequence, using max-heap and min-heap. Even before completing the code the compiler returned me an…
-
0
votes1
answer115
viewsLimit registration permission system
In my course system, the instructor has to stipulate the number of students who can enroll in each class and the student will only be able to enroll if the number of students enrolled is lower than…
-
0
votes2
answers71
viewsPHP comparator " != "
I’m having some difficulty with the following code; //Verifica Se o usuario esta cadastrado no Codelist $query = "select trim(loginid) loginid from yfs_user where loginid = '$USER'"; $stmt =…
-
0
votes1
answer92
viewsProblem with my Rock, Paper and Scissors game
I have a problem with the job maquina(), the function is not able to perform any action, think the function is not receiving the value of the variable jgdJogador. var comecar = false, i = 1; if (i…
-
0
votes0
answers23
viewscomparing javascript objects
to compare objects in javascript, I could turn these objects into strings and then compare them? would the result be correct? follows below what I did: let equalsString = (a, b) => { let…
-
0
votes1
answer694
viewsPython - Dataframe - Create a new Dataframe from comparing two other Dataframe
I have a question, and I’d like your help. I have two Dataframe and I need to compare if some columns of these Dataframe are the same and, if they are the same, then I need to store this record in…
-
0
votes2
answers489
viewsCompare two Dataframe and create a new Dataframe
I have a question and would like your help. I have two Dataframe and I need to compare some columns of these Dataframe are equal and, if they are equal, then I need to store the records in another…
-
0
votes0
answers59
viewsProgram that Tells how many repeated numbers you have in the column and row of an array
To simplify, I have to make this ex: **Write a program that reads two sequences of ten integer numbers and prints on screen how many of these numbers are present in the two sequences and how many…
-
0
votes1
answer143
viewsVector comparison program C++
You guys all right? I’m beginner and I’m trying to build a program that compares two vectors and if all the elements of the two vectors are. I’ll exemplify it to get better... vector 1 = 10, 20 , 30…
-
0
votes1
answer27
viewsHow to compare 2 different Hashmaps in Java
I have 2 Strings that convert to Hashmaps, the first is an input that the user gives to the application. The second is an Array that contains a lot of words. I need to compare both Hashmaps to see…
-
0
votes0
answers23
viewsNeed to test heterocedasticity before using the Kruskal-Wallis test
My question is whether or not to test heterodasticity before using the Kruskal-Wallis test. What I understand is that if I want to compare medians/mean, then I have to check for heterocedasticity,…
-
0
votes1
answer62
viewsCode error for letter detection
I’m working on a code for letter detection using a function, for a classroom exercise. The idea is that when I type a letter the function detects if it is: maiscula = 1 minuscule = 0 something else…
-
0
votes0
answers12
viewsCannot compare variables in C
My code should recognize the character "(". But unfortunately it does not recognize, and I do not know why. Breakable Ahead starts with "(", but when I compare it to '(', it falls on the last Esol,…
-
0
votes1
answer38
viewsRepeated hunch
Hey, here’s my problem. I’m developing an application in c# (console) to learn c# and I’m having a problem that I can’t solve. First I draw the numbers that will be drawn: Random rnd = new Random();…
-
-1
votes1
answer458
viewsDifference of dates with Legend in a Textfield
I am developing a hotel system and would like to automate some features in the system. I would like that when you select two dates being the dataEntrada and dataSaida using Calendar, make that when…
-
-1
votes1
answer41
viewsComparison between Objects always returns false
Why even with that: ValidacaoHelper.saoIguais(3044, 3044), that is, with equal parameters, the return is false? /** * @param obj * objeto a ser validado * @return TRUE se o objetos passados por…
-
-1
votes1
answer168
viewsHow to compare two lists of names in python?
Hello, all right? So I have two lists in pdf and I would like to get the names of the people who are on both lists. How would you do this in python? It would be better in another language?…
-
-1
votes2
answers161
viewsTerminate program with enter/ EOF
I need the code to end after an empty enter, with no input or the 'EOF', but I don’t know how to apply it and I didn’t understand very well the examples I saw. The program is almost complete, it…
-
-1
votes1
answer56
viewsIn the vector category pair<string, int>: When adding a new string, check whether a future string has the same value as an already added string
And if so, change the value of the previously added pair instead of adding a new pair. So, I’d like to add string pairs, int into an array, only, to avoid redundant pairs, check if the string…
-
-1
votes1
answer24
viewsCheck between excel and windows lists
good afternoon. I’m developing a program that has 3 stages: 1st Stage: Read a certain directory on Windows that contains multiple subfolders and return me a listing with the name of all the files…
-
-1
votes1
answer446
viewsStruct with string in C
I have a tremendous question, I did this algorithm here on C, I need to register patients, name, age, sex, if he’s in the risk group, if he’s with covid 19, then I need to count how many are male…
-
-1
votes1
answer31
viewsCompare the current date to the due date and fire an email if Expired!! - PHP Javascript
I need to do a Javascript function that if it is missing 1 month for the "validade_driver" to expire, the text of the HTML table is changed from "Valid" to "Expired", and an email is sent to the…
-
-1
votes2
answers40
viewsManual String Breaking in JAVA
Gentlemen, I am trying to do a routine that receives a certain text and a word from the user, after checking if within the text there is a word equal to what was requested. My attempt was to…
java comparison string-concatenation characters jtextareaasked 3 years, 8 months ago Gabriel Galdino 3 -
-2
votes1
answer157
viewsComparison of elements of a vector with "strcmp()"
In the following function I want to compare the elements of a array of 1000, but I can’t find a way to successfully compare them, even using strcmp(). void verifica_conta(int *ptr) { int i;…
-
-2
votes1
answer93
viewsphp function cannot compare words with accents
I have a function that compares 2 words, but when removing the accents, it still identifies as different words: function acento($str, $from, $to) { $keys = array(); $values = array();…
-
-2
votes1
answer30
viewsIn a df, how to select items in column with datetime format, classify them into periods (morning, afternoon and evening) and place them in a new column
Hello!!! I am looking for help to solve the problem below. My df has a ' DATA column with format 29/01/2019 17:50:11), which by default is converted to 'object' type pandas. All in all, it has 640…