I am new to typescript. Recently I have added ES-lint to react native project. IN my project I have used == instead of === as it was required. Removing == increases my no of lines of code, which may result to increase time complexity. To what solution I should go for. Removing == or increasing line of codes. I have already checked  this link but does not answer my question. I am aware about different use of == and ===. But here is the condition i do not want to check the type but only values. My question is just that is it strictly avoided to use ==.
I'm using  to go through JavaScript, and it's returning many suggestions to replace == (two equals signs) with === (three equals signs) when doing things like comparing idSele_UNVEHtype.value.length == 0 inside of an if statement.  Is there a performance benefit to replacing == with ===?   Any performance improvement would be welcomed as many comparison operators exist.  If no type conversion takes place, would there be a performance gain over ==?
When I receive a message on an SE post, I get a notification like this:    If I double tap this notification, the SE application opens, but my feed is empty approximately half the time. It looks like this:    If I refresh the feed (slide from the top), the feed does refresh and shows the new notification.   The notification, above, leads to  comment.  I haven't figured out the pattern yet, but this occurs roughly half the time I open a notification. It's occurred for chat messages, comments and answers - but not consistently. I have received notifications for the same post (for example, the two comments after the one linked above) that do not show an empty feed. But, a chat message barely 10 minutes later will show the empty feed again.  I am utilizing the beta app - version 1.0.72 on Android 5.0.1. Find each line matching a pattern but print only the line above it I need to find a string and need to print the line above it.   case1: The same line won't have the more than one matching pattern   ie)  consider a file containing  $cat &gt; para returns between the paragaraphs italic or bold     quotes by placing italic   Here i need to find for italic, and i need to get the output as below   returns between the paragaraphs quotes by placing   How can i get the output like this? de morgan law $A\setminus (B \cap C) = (A\setminus B) \cup (A\setminus C) $ First part :  I want to prove the following De Morgan's law :  ref.(dfeuer)  $A\setminus (B \cap C) = (A\setminus B) \cup (A\setminus C) $    Second part:  Prove that $(A\setminus B) \cup (A\setminus C) = A\setminus (B \cap C) $    Proof:  Let $y\in (A\setminus B) \cup (A\setminus C)$     $(A\setminus B) \cup (A\setminus C) = (y \in A\;  \land y \not\in  B\;) \vee (y \in A\; \land y \not\in C\;)$      $\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;= y \in A\ \land (  y \not\in B\; \vee \; y \not\in C ) $      $\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;= y \in A \land  (\lnot ( y\in B) \lor \lnot( y\in C) )$   According to De-Morgan's theorem :  $\lnot( B \land C) \Longleftrightarrow (\lnot B \lor \lnot C)$ thus     $y \in A \land (\lnot ( y\in B) \lor \lnot( y\in C) ) = y \in A \land y \not\in (B \land C)$   We can conclude that  $(A\setminus B) \cup (A\setminus C) = A\setminus (B \cap C)$ What is a 'Closure'? I asked a question about Currying and closures were mentioned. What is a closure? How does it relate to currying? An explanation of Hawking Radiation What's the associated matrix of this linear operator? Let $V$ be a complex vector space of dimension $n$ with a scalar product, and let $u$ be an unitary vector in $V$. Let $H_u: V \to V$ be defined as  $$H_u(v) = v - 2 \langle v,u \rangle u$$  for all $v \in V$. I need to find the characteristic polynomial of this linear operator, but the only way to find it that I know of is using the associated matrix of the operator.  I don't know how to find this matrix because I don't know how to deal with the scalar product. Is there some other way to find the characteristic polynomial? If not, how can I find the associated matrix of this linear operator?  Thanks in advance. I am trying to install Ubuntu 12.10 for quite some time, and passing hurdles one by one. Now I am in a situation as follows.  I have got a PC and 10 GB HDD which will be totally dedicated to Ubuntu so no option of Wubi and dual boot.  I was trying to install from DVD, but it is getting stuck at "Out of frequency" error. So I had to adapt for USB boot option. But my PC is USB non bootable, so workaround is "Plop Boot Manager". So I am doing the installation procedure as follows:   starting  from a CD drive which is having plop installed. opting for for USB boot in plop options. booting begins from USB. monitor eventually gives "out of frequency" error press Shift+Alt+F1 to get the terminal. open the grub with sudo nano /etc/default/grub. do necessary changes. sudo update-grub.   Now here I am getting error as follows:   /usr/sbin/grub-probe:error:failed to get canonical path of /cow.     My system is   P4 3.06 GHz, 1 GB ram , 10 GB HDD without an OS, monitor CRT lg StudioWorks (7 years old). Mobo Mercury P4 266a NDMx (865 equivalent). The whole system is perfectly in working condition under XP, but it is USB non bootable, and all other devices working perfectly.  What should I do next? Intuitive explanation for density of transformed variable? Suppose $X$ is a random variable with pdf $f_X(x)$. Then the random variable $Y=X^2$ has the pdf   $$f_Y(y)=\begin{cases}\frac{1}{2\sqrt{y}}\left(f_X(\sqrt{y})+f_X(-\sqrt{y})\right) &amp; y \ge 0 \\ 0 &amp; y \lt 0\end{cases}$$   I understand the calculus behind this. But I'm trying to think of a way to explain it to someone who doesn't know calculus. In particular, I'm trying to explain why the factor $\frac{1}{\sqrt{y}}$ appears out front. I'll take a stab at it:  Suppose $X$ has a Gaussian distribution. Almost all the weight of its pdf is between the values, say, $-3$ and $3.$ But that maps to 0 to 9 for $Y$. So, the heavy weight in the pdf for $X$ has been extended across a wider range of values in the transformation to $Y$. Thus, for $f_Y(y)$ to be a true pdf the extra heavy weight must be downweighted by the multiplicative factor $\frac{1}{\sqrt{y}}$  How does that sound?  If anyone can provide a better explanation of their own or link to one in a document or textbook I'd greatly appreciate it. I find this variable transformation example in several intro mathematical probability/stats books. But I never find an intuitive explanation with it :( give a variable to an operator For a workflow tool I made a panel in which it displays each separate library that is linked in my file. For each library I want to add some buttons that does stuff to the library in question.  So in this example I have my panel which shows for example 2 libraries and for each one it creates a "reload" button.  Now my question is.. How do I make it so the reload button only reloads the library I want to reload? I would probably have to give the button an id or something so it knows for which library it was created...  my code so far:  import bpy  libs = bpy.data.libraries  class Reloadlib(bpy.types.Operator):     """Reloads the current Library"""     bl_idname = "my.reload_lib"     bl_label = "Reload"      def execute(self, context):         libs[?????].reload()         self.report({'INFO'}, 'Reloading ' + libs[?????].name)         return {'FINISHED'}  class LibPanel(bpy.types.Panel):     """Creates a Panel in the scene context of the properties editor"""     bl_label = "Scene Libraries"     bl_idname = "SCENE_PT_layout"     bl_space_type = 'PROPERTIES'     bl_region_type = 'WINDOW'     bl_context = "scene"      def draw(self, context):         layout = self.layout         scene = context.scene         layout.label(text="Libraries:")          for i in libs:             layout.label(text= i.name.replace(".blend",""))             row = layout.row()             sub = row.row()             sub.operator("my.reload_xref", icon = "FILE_REFRESH")  def register():     bpy.utils.register_class(Reloadlib)     bpy.utils.register_class(LibPanel)  def unregister():     bpy.utils.unregister_class(Reloadlib)     bpy.utils.unregister_class(LibPanel)  if __name__ == "__main__":     register()   Where the question marks are is where I should be able to make the difference between the first [0] or second [1] library in the libs[] array.  In future I would also like to ad an 'open' and an 'unlink' button for each library so I can make changes to the other file. But this works by the same principle as the reload button. Boundary of Ball of radius R has zero measure $24\mid n(n^{2}-1)(3n+2)$ for all $n$ natural problems in the statement. Qt: Best practice for a single instance app protection Picturing the how the covariant derivative acts on vector fields After the DEM creation, I wanted to create slope layer.   However, the result has not satisfied me. I don't think the slope map is correct. Have you ever encountered false calculated terrain map?  This is the DEM:    And this is the slope layer. LINQ's Distinct() on a particular property I am playing with LINQ to learn about it, but I can't figure out how to use Distinct when I do not have a simple list (a simple list of integers is pretty easy to do, this is not the question). What I if want to use  on a list of an Object on one or more properties of the object?  Example: If an object is Person, with Property Id. How can I get all Person and use Distinct on them with the property Id of the object?  Person1: Id=1, Name="Test1" Person2: Id=1, Name="Test1" Person3: Id=2, Name="Test2"   How can I get just Person1 and Person3? Is that possible?  If it's not possible with LINQ, what would be the best way to have a list of Person depending on some of its properties in .NET 3.5? WCF server-side timeout concurrentModificationException I have a 8 GB pendrive. I used to write raw data into the pendrive (without creating filesystem) using the dd command.    Today, when I inserted the pen drive, the I am unable to write anything on to it.  When I open gparted it is showing the total space on the pen drive as 500 MB. I am unable to create a new partition table or a partition on the pen drive now.   Here is the fdisk -l output.   Disk /dev/sdb: 0 MB, 512000 bytes 255 heads, 63 sectors/track, 0 cylinders, total 1000 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 4096 bytes I/O size (minimum/optimal): 4096 bytes / 4096 bytes Disk identifier: 0x00095df6   What's wrong with the pen drive? How can I recover the lost space?   Device Boot      Start         End      Blocks   Id  System   When I open gnome-disks, it shows the total space as 8 GB but when I try to create a new partition using it, it shows the following error:  Error creating partition on /dev/sdb: Command-line parted --align optimal --script "/dev/sdb" "mkpart primary ext2 1MiB 7969177599b"' exited with non-zero exit status 1: Error: The location 7969177599b is outside of the device /dev/sdb.  (udisks-error-quark, 0) Can command substitution be nested in variable substitution? Sqlite3 by default sorts only by ascii letters. I tried to look in google, but the only thing I found were informations about collations. Sqlite3 has only NOCASE, RTRIM and BIARY collations. How to add support for a specific locale? (I'm using it in Rails application)