My question is that many documentation over mutable strings, I have read that StringBuilder gives faster result as compare to StringBuffer. People gives reason that, StringBuilder is not synchronized and StringBuffer is synchronized, but it gives same result even with single thread. Please give me the valid reason for that.
What is the main difference between StringBuffer and StringBuilder? Is there any performance issues when deciding on any one of these?
Do I need a transit visa to collect and re-check my luggage at Istanbul Ataturk airport? I'm Egyptian and flying to Cairo from Tbilisi, via Istanbul. The first flight Tbilisi-Istanbul is on Atlasjet, then from Istanbul to Cairo I am flying on Egyptair. For that, I have to recheck in at Istanbul to my Egyptair flight  Will I need to pass passport control at Istanbul airport to collect my bags and check in on Egyptair? Will I need a transit visa for that? Or it can be all done through neutral zone? Is it possible to stop my laptop going to sleep when I close the lid?  GNOME 3.20, Fedora 24.    My laptop does not reliably wake from sleep.  (It happens to be a hardware issue... I think I basically killed it while trying to replace a wifi card.  But I want to keep using it for a while longer). Ignore folders/files when Directory.GetFiles() is denied access Prove the divisibility test by $7,11,13$ for numbers more than six digits Convert string to Title Case with JavaScript Is there a simple way to convert a string to Title Case? E.g. john smith becomes John Smith. I'm not looking for something complicated like , just (hopefully) some kind of one- or two-liner. I am wondering how to show that $\mathbb{Z}[\sqrt {10}]$ is not a UFD.    My only idea is to show that there are two factorizations of $10$, say, $ab, uv$ such that $a$ is not a unit times $u$ or $v$. In this ring $10=2\cdot5=\sqrt {10}\cdot \sqrt {10}$, so it suffices to show $2$ is not a unit times $\sqrt {10}$. Suppose $2=\sqrt {10}(a+b\sqrt{10})=a\sqrt{10}+10b$. Then $a=0$ since $\sqrt{10}$ is not rational. So $10b=2$, which has no integer solutions. So $\mathbb{Z}[\sqrt {10}]$ is not a UFD.  Is my reasoning correct? What are the flaws? Almost universal class I so stuck with a problem of set theory. But first a recursive definition:   Define $R_0=\emptyset$ If $R_\alpha$ is defined, then $R_{\alpha+1}=\mathcal{P}(R_\alpha)$ (the power set). For a limit ordinal $\gamma$, if $R_\alpha$ is defined for all $\alpha&lt;\gamma$, then define $R_\gamma=\displaystyle\bigcup_{\alpha&lt;\gamma} R_\alpha$   We define $\text{BF}=\displaystyle\bigcup_{\alpha\in\text{OR}} R_\alpha$ (the class of well founded sets).  Next, my problem     Take $A\subseteq \text{BF}$ a proper transitive class such that $(A,\in)\models\text{ZF}$. Prove that $A$ is almost universal.    I think that the exercise is false because if it was true, then we could conclude that the strongly inaccessible cardinals doesn't exists. This because if $\kappa$ is strongly inaccessible then $R_\kappa$ satisfies the hypothesis but $R_\kappa$ isn't almost universal. I really appreciate any hint or/and suggestion.   Edit: my counterexample is wrong. But, then, how can I solve the exercise? Is it valid to have more than one question mark in a URL? The bottom border on the timeline page looks wrong if a title is multiline How can you tell when a roast is done? How can you tell when a roast is done?  How long should they roast for? How to unplug a network cable that's stuck? Consider a common proof of the uncountability of $(0,1]$, as presented  for example:  We assume that the reals can be arranged in a sequence $x_k$, represent every number in $x_k$ by its nonterminating decimal expansion, use the diagonal argument to create a sequence of decimal digits that differs from the nonterminating decimal expansion of each number in $x_k$ and then claim that this sequence of digits so generated must be the decimal expansion of some number not in $x_k$.  My problem is with this last step. Could it not be the case that the new sequence of digits is just the terminating decimal expansion of some number already in $x_k$?  Would it not be more correct to use the sequence $x_k$ to generate a sequence of all (both terminating and non-terminating) decimal expansion of all numbers in $[0,1)$ and then apply the diagonal argument? Where did the "Magic Blood" of the Harry Potter Universe Originate From? What is a wizard that makes them non-Muggle? Or, more directly, what ancestry does the witch/wizard gene follow? Is there a patriarchal wizard (or matriarchal witch) that Muggles have no part in? Elves perhaps? Stop reading here.  Purpose of the Question/History/Don't Read There seem to be solid consequences associated with being Muggle, or Muggle-related. A dominant theme in the novels is discrimination against the non-gifted race, but, when read into, the wizard bloodline doesn't appear all that well defined. JKR indicates that wizard-ness is genetic, or inherited:  &quot;Muggle-borns will have a witch or wizard somewhere on their family tree, in some cases many, many generations back. The gene resurfaces in some unexpected places.&quot;  By the above, it stands that a family that produces a squib (non-magical born of magical parents) must be a half-blooded family in some way, since half-blooded only requires one non-magical ancestor. Of course, we are dealing in magic genetics. Any other form of genetics would make this inherited, seemingly recessive trait (or squibs couldn't exist), never appear at all. Unless they were XMen. If it is so important, what does the wizard-bloodline follow? Other Mythos In other literature a wizard can be nearly anything, but magical powers are typically inherited as well as learned. Merlin of the Arthurian Legend (also mentioned in HP) is Cambian, meaning he is born of demonic intervention; this explains his source of enchantment. Gandalf of Middle Earth is a Maiar, as are all Wizards of Middle Earth. Wizards in Harry Potter seem to follow a bloodline, and it has been mentioned (in the question Gabe linked) that genetics have a heavy play in it, meaning that squibs and parents of Muggle-born wizards should have identical genetics. This bloodline must come from somewhere. Magical Creatures In Harry Potter it is common for magical creatures to &quot;mingle&quot; with humans, these beings are typically somewhat magical. Elves have been described to have very strong magic, but are for some unreasonable reason subservient to humans. I may be mistaken, but believe it was hinted that elves and the wizarding lineage had intersected at one time. Maybe I'm imagining this. Genocidal Allusions Voldemort hates muggles, and half-bloods, and whatever else is non-wizard. The presence of this theme, suggests that this wizardly bloodline must be at least defined if the main antagonist is so obsessed with keeping that mysterious bloodline pure. Since Slytherin himself was said to be a supremacist (circa a really long time ago) it suggests that this bloodline should have existed long before he was around, especially if he founded a school with people he was not related to, but were also magical. How can I save my hardcore map after I die? My brother jumped into the voice of the doom in my Hardcore Creative map. I didn't press the ΄΄Delete This World΄΄ button yet. The Ubuntu installer does not allow me to install on NTFS partitions, but certain circumstances requires me to do so. Is it possible? Dynamically Create a generic type for template I'm programming WCF using the ChannelFactory which expects a type in order to call the CreateChannel method. For example:   IProxy proxy = ChannelFactory&lt;IProxy&gt;.CreateChannel(...);   In my case I'm doing routing so I don't know what type my channel factory will be using. I can parse a message header to determine the type but I hit a brick wall there because even if I have an instance of Type I can't pass that where ChannelFactory expects a generic type.   Another way of restating this problem in very simple terms would be that I'm attempting to do something like this:  string listtype = Console.ReadLine(); // say "System.Int32" Type t = Type.GetType( listtype); List&lt;t&gt; myIntegers = new List&lt;&gt;(); // does not compile, expects a "type" List&lt;typeof(t)&gt; myIntegers = new List&lt;typeof(t)&gt;(); // interesting - type must resolve at compile time?   Is there an approach to this I can leverage within C#? How to insert page number in Beamer navigation symbols? How can i make my Java Swing GUI Components [Right To Left] for Arabic language from NetBeans Desktop Application? How to not have an equation in the first line using the align environment? Prove：$x^d-1 \mid x^n-1$ iff $d \mid n$. Consider the polynomial ring $F\left[x\right]$ over a field $F$. Let $d$ and $n$ be two nonnegative integers. Prove：$x^d-1 \mid x^n-1$ iff $d \mid n$.  my tries:  necessity, Let $n=d t+r$, $0\le r&lt;d$ since $x^d-1 \mid x^n-1$, so, $x^n-1=\left(x^d-1\right)\left(x^{\text{dt}+r-d}+\dots+1\right)$... so,,, to prove $r=0$? I don't know, and I can't go on. How to do it.