Skip to main content

Questions tagged [difference]

This tag may refer to 1) the difference between two numbers (i.e. the difference between 5 and 10 is 5) or 2) the things that two or more particular objects do not share in common.

difference
Filter by
Sorted by
Tagged with
850 votes
10 answers
358k views

What's the difference between a module and package in Python?

What's the difference between a module and package in Python? See also: What's the difference between "package" and "module"? (for other languages)
Dave's user avatar
  • 9,283
829 votes
13 answers
674k views

Differences between Oracle JDK and OpenJDK

NOTE: This question is from 2014. As of Java 11 OpenJDK and Oracle JDK are converging. Are there any crucial differences between Oracle and OpenJDK? For example, are the garbage collection and ...
user1340582's user avatar
  • 19.5k
401 votes
12 answers
504k views

Java 8: Difference between two LocalDateTime in multiple units

I am trying to calculate the difference between two LocalDateTime. The output needs to be of the format y years m months d days h hours m minutes s seconds. Here is what I have written: import java....
Tapas Bose's user avatar
  • 29.5k
376 votes
22 answers
423k views

What is the difference between JVM, JDK, JRE & OpenJDK?

What is the difference between JVM, JDK, JRE, and OpenJDK?
Alireza's user avatar
  • 4,393
368 votes
17 answers
240k views

What's the difference between ViewData and ViewBag?

I saw the ViewBag in MVC 3. How's that different than ViewData in MVC 2?
user469652's user avatar
  • 50.5k
362 votes
12 answers
144k views

What is the difference between memoization and dynamic programming?

What is the difference between memoization and dynamic programming? I think dynamic programming is a subset of memoization. Is it right?
Sanghyun Lee's user avatar
  • 22.5k
285 votes
22 answers
519k views

Get time difference between datetimes

How to get the difference between 2 times? Example: var now = "04/09/2013 15:00:00"; var then = "04/09/2013 14:20:30"; //expected result: "00:39:30" I tried: var now = ...
Leo's user avatar
  • 7,429
275 votes
9 answers
223k views

What is the difference between bottom-up and top-down?

The bottom-up approach (to dynamic programming) consists in first looking at the "smaller" subproblems, and then solve the larger subproblems using the solution to the smaller problems. The top-down ...
Guest's user avatar
  • 3,167
224 votes
3 answers
106k views

“Diff” an image using ImageMagick

How can I get the difference between two images? I have the original image. Someone has written on an exact duplicate of the original image. Now, I need to compare the original to the written on image ...
Justin Noel's user avatar
  • 6,095
201 votes
8 answers
104k views

What is the difference between HashSet<T> and List<T>?

Can you explain what is the difference between HashSet<T> and List<T> in .NET? Maybe you can explain with an example in what cases HashSet<T> should be preferred against List<T&...
pencilCake's user avatar
  • 52.7k
200 votes
8 answers
101k views

What's the difference between "squash" and "fixup" in Git/Git Extension?

I've been using Git Extensions for a while now (it's awesome!) but I haven't found a simple answer to the following: Sometimes, when typing a commit message, a make a typo. My friend showed me how to ...
Purple Dragon's user avatar
199 votes
8 answers
189k views

Difference between IsNullOrEmpty and IsNullOrWhiteSpace in C# [duplicate]

What are differences between these commands in C# string text= " "; 1-string.IsNullOrEmpty(text.Trim()) 2-string.IsNullOrWhiteSpace(text)
Asieh hojatoleslami's user avatar
181 votes
3 answers
157k views

window.location.href vs window.location.replace vs window.location.assign in JavaScript

What is the difference between window.location.href="http://example.com"; window.location.replace("http://example.com"); window.location.assign("http://example.com"); I read in many forums that ...
milan_9211's user avatar
  • 1,979
160 votes
5 answers
88k views

What is the difference between size and count in pandas?

That is the difference between groupby("x").count and groupby("x").size in pandas ? Does size just exclude nil ?
Donovan Thomson's user avatar
157 votes
15 answers
198k views

Flutter: Find the number of days between two dates

I currently have a user's profile page that brings out their date of birth and other details. But I am planning to find the days before their birthday by calculating the difference between today's ...
Asyraf Dayan's user avatar
  • 3,001
152 votes
9 answers
95k views

Android - Snackbar vs Toast - usage and difference

We have been using just Toasts in our application so far and as we are planning to adopt some new features from Support Design Library I am wondering what's the recommended usage for Snackbar vs. ...
Jakub Holovsky's user avatar
150 votes
5 answers
79k views

Difference between HBase and Hadoop/HDFS

This is kind of naive question but I am new to NoSQL paradigm and don't know much about it. So if somebody can help me clearly understand difference between the HBase and Hadoop or if give some ...
Dhaval Shah's user avatar
  • 1,515
98 votes
5 answers
111k views

What are the differences between activity and fragment?

As per my research, there is a significant difference in the concept of backstack and how they exist: Activity When an activity is placed to the backstack of activities the user can navigate back to ...
Devrath's user avatar
  • 42.7k
95 votes
3 answers
41k views

Java: what exactly is the difference between NIO and NIO.2?

I don't quite understand how different they are from each other so I have some inquiries regarding these two packages. After looking around a bit on Google, it seems like Oracle decided to update the ...
John Huynh's user avatar
75 votes
14 answers
160k views

Android difference between Two Dates

I have two date like: String date_1="yyyyMMddHHmmss"; String date_2="yyyyMMddHHmmss"; I want to print the difference like: 2d 3h 45m How can I do that? Thanks!
D Ferra's user avatar
  • 1,223
75 votes
1 answer
24k views

Package vs Library

I've just started working with CMake and I noticed that they have both a find_package and a find_library. And this confuses me. Can somebody explain the difference between a package and a library in ...
assignment_operator's user avatar
74 votes
2 answers
88k views

What are the differences between MPI and OpenMP? [closed]

I would like to know (in a few words) what are the main differences between OpenMP and MPI.
elli's user avatar
  • 1,159
70 votes
2 answers
105k views

What's the difference between Mockito Matchers isA, any, eq, and same?

I am confused on what's the difference between them, and which one to choose in which case. Some difference might be obvious, like any and eq, but I'm including them all just to be sure. I wonder ...
Silly Sally's user avatar
  • 1,127
67 votes
8 answers
44k views

What's the difference between convolutional and recurrent neural networks? [closed]

I'm new to the topic of neural networks. I came across the two terms convolutional neural network and recurrent neural network. I'm wondering if these two terms are referring to the same thing, or, ...
Tal_'s user avatar
  • 761
60 votes
6 answers
120k views

Typescript difference between two arrays

Is there a way to return the missing values of list_a from list_b in TypeScrpit? For example: var a1 = ['a', 'b', 'c', 'd', 'e', 'f', 'g']; var a2 = ['a', 'b', 'c', 'd', 'z']; The result value is ['e'...
Galma88's user avatar
  • 2,506
60 votes
7 answers
136k views

row-level trigger vs statement-level trigger

I am having a hard time understanding the difference between 'row-level triggers' and 'statement-level triggers'. From my understanding, in the scenario a statement level trigger is created, the whole ...
Gregorio Di Stefano's user avatar
59 votes
4 answers
69k views

Queue<T> vs List<T>

I'm currently using a List<T> as a queue (use lst[0] then lst.removeAt(0)) to hold objects. There's about 20 items max at a given time. I realized there was an actual Queue<T> class. I'...
Jack's user avatar
  • 5,738
57 votes
6 answers
66k views

What is the difference between cross-validation and grid search?

In simple words, what is the difference between cross-validation and grid search? How does grid search work? Should I do first a cross-validation and then a grid search?
Linda's user avatar
  • 2,395
50 votes
4 answers
123k views

CV - Extract differences between two images

I am currently working on an intrusion system based on video surveillance. In order to complete this task, I take a snapshot of the background of my scene (assume it's totally clean, no people or ...
Valentin Trinqué's user avatar
45 votes
1 answer
70k views

The difference between head & tail recursion [duplicate]

I'm trying to get the difference between these 2 recursive strategies. The definition I was told is the following: Tail Recursion: A call is tail-recursive if nothing has to be done after the call ...
Scarl's user avatar
  • 950
43 votes
3 answers
23k views

what is the usage of HTML5 figure with img

Is there any specific advantage/usage of using HTML5 <figure> over <img>? I think <figure> is useless without <figurecaption>, isn't it? It will be helpful if explain with an ...
xkeshav's user avatar
  • 53.4k
42 votes
1 answer
46k views

How to compare/show the difference between 2 videos in ffmpeg?

I am a newbie at encoding. I have read and tried x264 in lossless mode (-qp 0), however I'd like to make sure that in my new video, every single pixel contains the same information as the source file (...
polarka's user avatar
  • 576
41 votes
2 answers
22k views

(git) diff output relative path?

I need to get some diffs in my repo that are not relative to the base of the repo, but instead relative to a given base or given path. By default I get: git diff diff --git a/path/to/file b/path/to/...
user318904's user avatar
  • 3,038
40 votes
2 answers
55k views

Difference between ANSI and Unicode drivers of MySQL

On choosing Data Source under ODBC (64-Bit) on Windows, i get two available options of MySQL Database: MySQL ODBC 5.3 ANSI Driver MySQL ODBC 5.3 Unicode Driver What are the difference between these ...
Malwinder Singh's user avatar
37 votes
2 answers
24k views

What is the Difference Between x:Key, x:Name, and x:UID in a DataTemplate in WPF?

I am trying to create dynamic tabs in WPF, and I'm trying to write a content template that will only apply to some tab items. I want to be able to create an identifier for the content template so that ...
user3685285's user avatar
  • 6,396
36 votes
6 answers
283k views

Calculate time difference in minutes in SQL Server

I need the time difference between two times in minutes. I am having the start time and end time as shown below: start time | End Time 11:15:00 | 13:15:00 10:45:00 | 18:59:00 I need the ...
prabu R's user avatar
  • 2,179
36 votes
5 answers
46k views

Differences between ComboBox and ChoiceBox in JavaFX

What are the differences between ComboBox and ChoiceBox in JavaFX? I'm not entirely clear on that just from the Javadoc for both classes. At the end of the day, I need a dropdown control that can be ...
Slayer0248's user avatar
  • 1,241
35 votes
6 answers
13k views

How do I get PyCharm to show entire error diffs from pytest?

I am using Pycharm to run my pytest unit tests. I am testing a REST API, so I often have to validate blocks of JSON. When a test fails, I'll see something like this: FAILED test_document_api.py:0 (...
W.P. McNeill's user avatar
  • 16.8k
34 votes
4 answers
63k views

Difference between np.dot and np.multiply with np.sum in binary cross-entropy loss calculation

I have tried the following code but didn't find the difference between np.dot and np.multiply with np.sum Here is np.dot code logprobs = np.dot(Y, (np.log(A2)).T) + np.dot((1.0-Y),(np.log(1 - A2))....
Asad Shakeel's user avatar
  • 2,145
34 votes
2 answers
32k views

css difference between background: and background-image:

quick simple question In the following example of an external CSS page; body { background-image: url(background.jpg); } header { background: url(background.jpg); } I understand they are ...
epicT's user avatar
  • 363
31 votes
1 answer
26k views

How to calculate time difference by group using pandas?

Problem I want to calculate diff by group. And I don’t know how to sort the time column so that each group results are sorted and positive. The original data : In [37]: df Out[37]: id ...
Jack's user avatar
  • 1,734
31 votes
1 answer
128k views

Regex difference: (\w+)? and (\w*)

Is there any difference between (\w+)? and (\w*) in regex? It seems the same, doesn't it?
爱国者's user avatar
  • 4,328
28 votes
8 answers
7k views

In C# what is the difference between the upper and lower case String/string? [duplicate]

Newbie here, in C# what is the difference between the upper and lower case String/string?
user avatar
28 votes
1 answer
79k views

Difference between Ctrl K + D and Ctrl E + D

What is the difference between the Visual Studio 2010 shortcuts Ctrl E + D and Ctrl K + D?
user avatar
27 votes
9 answers
67k views

Find difference between two strings in JavaScript

I need to find difference between two strings. const string1 = 'lebronjames'; const string2 = 'lebronnjames'; The expected output is to find the extra n and log it to the console. Is there any way to ...
Elvis S.'s user avatar
  • 442
25 votes
7 answers
45k views

Difference between "import X" and "from X import *"? [duplicate]

In Python, I'm not really clear on the difference between the following two lines of code: import X or from X import * Don't they both just import everything from the module X? What's the ...
temporary_user_name's user avatar
25 votes
5 answers
51k views

Python find numbers not in set

I have a range of numbers such as 1-100. And I have a set that holds all, or a random subset of numbers in that range such as: s = set([1,2,3,35,67,87,95]) What is a good way to get all of the ...
Chris Dutrow's user avatar
  • 49.9k
25 votes
2 answers
21k views

What is the difference between a Confusion Matrix and Contingency Table?

I'm writting a piece of code to evaluate my Clustering Algorithm and I find that every kind of evaluation method needs the basic data from a m*n matrix like A = {aij} where aij is the number of data ...
MangMang's user avatar
  • 447
24 votes
1 answer
13k views

How to handle iterator::difference_type when you have no way of measuring the difference?

I'm writing a C++ wrapper for a 3rd party C library. The library provides some functions for iterating through a series of objects. I want to write an iterator to wrap this behaviour so iteration is ...
Pharap's user avatar
  • 4,017
23 votes
4 answers
33k views

Why do WPF Applications look different between Windows 7 and Windows 8 and can this be fixed?

I'm really surprised that this question does not appear to have been asked yet... if it has, but I just couldn't find it, apologies. Ok, so my work computer has just been upgraded from Windows 7 to ...
Sheridan's user avatar
  • 69.6k

1
2 3 4 5
40