I was watching friends lately and on that show Ross said "I haven't had sex in a very long time". I wonder why he didn't said "I haven't had sex for a very long time" although 'in a very long time' sounds more native and correct but why not he used  'for a very long time '.   So, this is my question when do we use 'in a very long time' and when do we use 'for a very long time'.
Now the cubs are growing, fed on mom's milk, but mom herself hasn't eaten in five months, and is getting thinner by the day.   What does in mean here, and how would the meaning of that piece change if for were used?
Multiple Inheritance in C# Since multiple inheritance is bad (it makes the source more complicated) C# does not provide such a pattern directly. But sometimes it would be helpful to have this ability. For instance I'm able to implement the missing multiple inheritance pattern using interfaces and three classes like that: public interface IFirst { void FirstMethod(); } public interface ISecond { void SecondMethod(); }  public class First:IFirst  {      public void FirstMethod() { Console.WriteLine(&quot;First&quot;); }  }  public class Second:ISecond  {      public void SecondMethod() { Console.WriteLine(&quot;Second&quot;); }  }  public class FirstAndSecond: IFirst, ISecond {     First first = new First();     Second second = new Second();     public void FirstMethod() { first.FirstMethod(); }     public void SecondMethod() { second.SecondMethod(); } }  Every time I add a method to one of the interfaces I need to change the class FirstAndSecond as well. Is there a way to inject multiple existing classes into one new class like it is possible in C++? Maybe there is a solution using some kind of code generation? Or it may look like this (imaginary c# syntax): public class FirstAndSecond: IFirst from First, ISecond from Second { }  So that there won't be a need to update the class FirstAndSecond when I modify one of the interfaces.  EDIT Maybe it would be better to consider a practical example: You have an existing class (e.g. a text based TCP client based on ITextTcpClient) which you do already use at different locations inside your project.  Now you feel the need to create a component of your class to be easy accessible for windows forms developers. As far as I know you currently have two ways to do this:  Write a new class that is inherited from components and implements the interface of the TextTcpClient class using an instance of the class itself as shown with FirstAndSecond.  Write a new class that inherits from TextTcpClient and somehow implements IComponent (haven't actually tried this yet).   In both cases you need to do work per method and not per class. Since you know that we will need all the methods of TextTcpClient and Component it would be the easiest solution to just combine those two into one class. To avoid conflicts this may be done by code generation where the result could be altered afterwards but typing this by hand is a pure pain in the ass. In educational material for the Russian language and linguistic literature the need to put accents on Cyrillic vowels often arises. However when I tried to do this with luaLaTeX the accents where misplaced.  \documentclass[11pt]{article} \usepackage[utf8]{inputenc} \usepackage{fontspec} \setmainfont{Linux Libertine:style=Regular} \begin{document}  Е́сли вы изу́чите  \'{Е}сли вы из\'{у}чите  \'{E}сли вы из\'{y}чите % Here "E" and "y" are Latin glyphs, but this workaround does not                         % work with all Cyrillic letters e.g. Я, Ю \end{document}     The last line would looks nice, but unfortunately these are Latin glyphs.  Is this a problem with the font used (Linux Libertine) or with LaTeX? How scientists can be confident that human embryo tail is really a tail? From :     Human embryos have a tail that measures about one-sixth of the size of the embryo itself. As the embryo develops into a fetus, the tail is absorbed by the growing body.   How are we sure that it is a real tail and is not a superficial resemblance of something else?  I ask this because some creationist guy challenged me in this regard. Social Login adoption vs Traditional Login I have implemented  on my website. I am wondering how important it is to include a traditional login (email/password) system.  I believe there may be a significant percentage of potential users that are either uncomfortable or unfamiliar with social login. These users may not sign up for my site if social login is the only option.  Does anyone know of any data comparing social login vs traditional login and the corresponding adoption rate?  Is there a current best practice? Do I need to give the user an option to sign up using username/password? Or is facebook/google/openID/twitter/MS/Yahoo enough? How to control Windows 7 snap feature with two monitors? There is an  feature in Windows 7. However, it seems to not work when dragging a window to the edge that is adjoined to the second monitor. How to make it work properly? Maybe some regedit modification or something? How can I chroot sftp-only SSH users into their homes? How to generate XML file dynamically using PHP? I have to generate a xml file dynamically at runtime. Please help me in generating the below XML file dynamically using PHP.  &lt;?xml version="1.0" encoding="UTF-8"?&gt; &lt;xml&gt;  &lt;track&gt;      &lt;path&gt;song1.mp3&lt;/path&gt;      &lt;title&gt;Track 1 - Track Title&lt;/title&gt;  &lt;/track&gt;  &lt;track&gt;      &lt;path&gt;song2.mp3&lt;/path&gt;      &lt;title&gt;Track 2 - Track Title&lt;/title&gt;  &lt;/track&gt;  &lt;track&gt;      &lt;path&gt;song3.mp3&lt;/path&gt;      &lt;title&gt;Track 3 - Track Title&lt;/title&gt;  &lt;/track&gt;  &lt;track&gt;      &lt;path&gt;song4.mp3&lt;/path&gt;      &lt;title&gt;Track 4 - Track Title&lt;/title&gt;  &lt;/track&gt;  &lt;track&gt;      &lt;path&gt;song5.mp3&lt;/path&gt;      &lt;title&gt;Track 5 - Track Title&lt;/title&gt;  &lt;/track&gt;  &lt;track&gt;      &lt;path&gt;song6.mp3&lt;/path&gt;      &lt;title&gt;Track 6 - Track Title&lt;/title&gt;  &lt;/track&gt;  &lt;track&gt;      &lt;path&gt;song7.mp3&lt;/path&gt;      &lt;title&gt;Track 7 - Track Title&lt;/title&gt;  &lt;/track&gt;  &lt;track&gt;      &lt;path&gt;song8.mp3&lt;/path&gt;      &lt;title&gt;Track 8 - Track Title&lt;/title&gt;  &lt;/track&gt; Are there specific techniques/filters for snowscapes? The Pearson correlation coefficient of x and y is the same, whether you compute pearson(x, y) or pearson(y, x). This suggests that doing a linear regression of y given x or x given y should be the same, but I don't think that's the case.   Can someone shed light on when the relationship is not symmetric, and how that relates to the Pearson correlation coefficient (which I always think of as summarizing the best fit line)? Suppose the terms of the sequence of real numbers $\{a_n\}$ satisfy $|a_{n+1} - a_n| \le 2^{-n}$ for all $n$. Prove that $\{a_n\}$ is Cauchy.   My Work  So by the definition of a Cauchy sequence, for all $\varepsilon &gt; 0$ $\exists N$ so that for $n,m \ge N$ we have $|a_m - a_n| \le \varepsilon$. However, questions like  make me understand that the $2^{-n}$ condition is necessary for this to be a true statement.   So I am wondering how to appeal to the Cauchy definition for this proof. Do I prove that every convergent sequence is therefore Cauchy, and then try to prove convergence? Trying to overwrite ... which is different from other instances of package I tried to upgrade Intel graphics in ubuntu 16.10 using the official installer. The last stage of unpacking libcairo2 produces an error (see figure).  When I do upgrade I get the same error also:   Preparing to unpack .../0-libcairo2_1.15.2-0intel1_amd64.deb ... Unpacking libcairo2:amd64 (1.15.2-0intel1) over (1.15.2-0intel1) ... dpkg: error processing archive /tmp/apt-dpkg-install-aYhdFd/0 libcairo2_1.15.2-0intel1_amd64.deb (--unpack): trying to overwrite shared '/usr/share/doc/libcairo2/changelog.Debian.gz', which is different from other instances of package libcairo2:amd64 Preparing to unpack .../1-libcairo2_1.15.2-0intel1_i386.deb ... Unpacking libcairo2:i386 (1.15.2-0intel1) over (1.15.2-0intel1) ... dpkg: error processing archive /tmp/apt-dpkg-install-aYhdFd/1-libcairo2_1.15.2-0intel1_i386.deb (--unpack): trying to overwrite shared '/usr/share/doc/libcairo2/changelog.Debian.gz', which is different from other instances of package libcairo2:i386 Errors were encountered while processing: /tmp/apt-dpkg-install-aYhdFd/0-libcairo2_1.15.2-0intel1_amd64.deb /tmp/apt-dpkg-install-aYhdFd/1-libcairo2_1.15.2-0intel1_i386.deb E: Sub-process /usr/bin/dpkg returned an error code (1)   It seems that there is a conflict in thelibcairo releases; if yes, how to resolve it ? Why do people sometimes use the past perfect form of a verb when the past would suffice? (e.g. "you had mentioned") I just updated from Ubuntu 10.10 to 11.04 and have an issue regarding the screen resolution. I have Intel integrated gfx chip and my monitor supports resolutions larger than 1024x768. (in 10.10 I've been using 1280x1024) But as soon as I upgraded, I'm stuck with 1024x768 resolution and seems I can't change it.  running xrandr In terminal yields the following results,   Screen 0: minimum 320 x 200, current 1024 x 768, maximum 4096 x 4096 LVDS1 connected 1024x768+0+0 (normal left inverted right x axis y axis) 0mm x 0mm    1280x800       58.1 +    1024x768       60.0*     800x600        60.3     56.2      640x480        59.9   VGA1 connected 1024x768+0+0 (normal left inverted right x axis y axis) 344mm x 194mm    1366x768       59.9 +    1360x768       60.0      1024x768       75.1     72.0     70.1     60.0*     832x624        74.6      800x600        72.2     75.0     60.3     56.2      640x480        72.8     75.0     66.7     60.0      720x400        70.1     1280x1024_60.00 (0xce)  109.0MHz         h: width  1280 start 1368 end 1496 total 1712 skew    0 clock   63.7KHz         v: height 1024 start 1027 end 1034 total 1063           clock   59.9Hz   What maybe the problem? Is it a bug? What kind of steps I should take in order to get a higher resolution? (changing xorg.conf maybe?) Any insight is highly appreciated. Thanks in advance.   UPDATE    Screenshot after running xrandr --addmode VGA1 1360x768  As you can see, side bar is not completely visible and Ubuntu logo at the task bar is missing. Also when you open an application, the Task bar of the application (where it should go to the top panel) is missing as well.. I am totally new to Linux, servers and websites. I recently set up Apache2, Python, PHP, and MySQL for setting up a LAMP server. I am using Xubuntu 16.04 and PHP 7.0.11. I followed a guide and placed a PHP file named testing.php in it with:  &lt;?php phpinfo(); ?&gt;    It doesn't show anything on localhost/testing.php All it shows is the code itself. Why do "stripes" appear on raster? I am reprojecting a SRTM 3 arc-second raster file from WGS84 geographic coordinate system, to projected coordinate system which is using Azimuthal Equidistant projection:  gdalwarp -s_srs EPSG:4326 -t_srs "+proj=merc +lat_ts=40.81266 +lon_0=14.414252" -r near -of GTiff C:/vesuvius2_wgs84.tif C:/vesuvius2_aeqd.tif   I attached the initial raster file in here ().  The issue is that if I use the Nearest neighbor resampling method (-r near), some sort of "stripes" appear on terrain once I reproject the file to Azimuthal Equidistant projection. Here is the how the reprojected raster looks like:    And here is its 3d representation:    Interestingly similar "stripes" appear in both direction if I reproject the initial raster to UTM:  gdalwarp -s_srs EPSG:4326 -t_srs EPSG:32633 -r near -of GTiff C:/vesuvius2_wgs84.tif C:/vesuvius2_epsg32633.tif   The "stripes" go away when I use Bilinear or Cubic resampling methods (-r bilinear, -r cubic) instead of the Nearest Neighbor one.  Why do these "stripes" appear when Nearest Neighbor resampling method is used? "going to" vs "will" In chapter 2 section 7 (pg 151) of Hartshorne's algebraic geometry there is an example given that talks about automorphisms of $\mathbb{P}_k^n$. In that example Hartshorne states that $\mathcal{O}(-1)$ has no global sections. However, we know that $\mathcal{O}(1)$ is generated by global sections. This is stated at the first of the section that if $\mathbb{P}_k^n = Proj k[x_0,...,x_n]$ then the $x_0,...,x_n$ give rise to global sections $x_0,...,x_n\in\Gamma(\mathbb{P}_k^n,\mathcal{O}(1))$.  I guess I don't understand this twisted structure sheaf very well, or to be honest I don't think I understand structure sheaves in general as well as I would like. The twisting part seems simple at first- you shift the grading of Proj over and then take the structure sheaf.  Admittedly I don't feel comfortable using the structure sheaf other than using the basic facts about it that Hartshorne gives when it is introduced. If anyone could give some insight as to what's going on here or how I might be able to understand this better it would be much appreciated. Thanks. Typsetting the Ponny Today, once again, the  came to my attention and I have decided to try to  using XeLaTeX. The result is far from perfect, worse even than Chrome's rendering.  Is there a way I can improve the result? Is XeLaTeX and LuaLaTeX incapable of handling the Ponny?  :  \documentclass[]{article} \usepackage{lmodern} \usepackage{amssymb,amsmath} \usepackage{ifxetex,ifluatex} \usepackage{fontspec} \defaultfontfeatures{Mapping=tex-text,Scale=MatchLowercase} \IfFileExists{upquote.sty}{\usepackage{upquote}}{} \IfFileExists{microtype.sty}{\usepackage{microtype}}{} \usepackage[normalem]{ulem} \setmainfont{Doulos SIL}  \title{html - RegEx match open tags except XHTML self-contained tags - Stack Overflow} \date{} \author{StackOverflow}  \begin{document} \maketitle  Rege̿̔̉x-based HTML parsers are the cancer that is killing StackOverflow \emph{it is too late it is too late we cannot be saved} the trangession of a chi͡ld ensures regex will consume all living tissue (except for HTML which it cannot, as previously prophesied) \emph{dear lord help us how can anyone survive this scourge} using regex to parse HTML has doomed humanity to an eternity of dread torture and security holes \emph{using rege}x as a tool to process HTML establishes a brea\emph{ch between this world} and the dread realm of c͒ͪo͛ͫrrupt entities (like SGML entities, but \emph{more corrupt) a mere glimp}se of the world of reg​\textbf{ex parsers for HTML will ins}​tantly transport a p\emph{rogrammer's consciousness i}nto a w\emph{orl}d of ceaseless screaming, he comes\sout{, the pestilent sl}ithy regex-infection wil​\textbf{l devour your HT}​ML parser, application and existence for all time like Visual Basic only worse \emph{he comes he com}es \emph{do not fi}​ght h\textbf{e com̡e̶s, ̕h̵i}​s un̨ho͞ly radiańcé de\emph{stro҉ying all enli̍̈́̂̈́ghtenment, HTML tags \textbf{lea͠ki̧n͘g fr̶ǫm ̡yo​͟ur eye͢s̸ ̛l̕ik͏e liq}​uid p}ain, the song of re̸gular exp​re\sout{ssion parsing} will exti\emph{​nguish the voices of mor​\textbf{tal man from the sp}​here I can see it can you see ̲͚̖͔̙î̩́t̲͎̩̱͔́̋̀ it is beautiful t​}he f\texttt{inal snuf}fing o\emph{f the lie​\textbf{s of Man ALL IS LOŚ͖̩͇̗̪̏̈́T A}}\textbf{LL I​S L}OST th\emph{e pon̷y he come}s he c̶̮om\sout{es he co}\textbf{\sout{me}s t\emph{he} ich​}or permeat\emph{es al}l MY FAC\emph{E MY FACE ᵒh god n\textbf{o NO NOO̼}}\textbf{O​O N}Θ stop t\emph{he an​*̶͑̾̾​̅ͫ͏̙̤g͇̫͛͆̾ͫ̑͆l͖͉̗̩̳̟̍ͫͥͨ}e̠̅s\texttt{ ͎a̧͈͖r̽̾̈́͒͑e} n\textbf{​ot rè̑ͧ̌aͨl̘̝̙̃ͤ͂̾̆ ZA̡͊͠͝LGΌ ISͮ̂҉̯͈͕̹̘̱ T}O͇̹̺ͅƝ̴ȳ̳ TH̘\textbf{Ë͖́̉ ͠P̯͍̭O̚​N̐Y̡ H̸̡̪̯ͨ͊̽̅̾̎Ȩ̬̩̾͛ͪ̈́̀́͘ ̶̧̨̱̹̭̯ͧ̾ͬC̷̙̲̝͖ͭ̏ͥͮ͟Oͮ͏̮̪̝͍M̲̖͊̒ͪͩͬ̚̚͜Ȇ̴̟̟͙̞ͩ͌͝}S̨̥̫͎̭ͯ̿̔̀ͅ  \end{document}   UPDATE  Using the Doulos SIL font gets me something closer to what Firefox renders but still far from perfect. "My wife and I's seafood collaboration dinner" I just stumbled upon a :     My wife and I's seafood collaboration dinner. How does it look?   Sure enough, the top comment immediately points out that it should be "my wife's and my". However, a cross-post to the Grammar subreddit produced :     It's fine as it is written. "my wife and I" is a noun phrase, functioning as a subjective pronoun in the singular and made possessive with the apostrophe. It is exactly the same as "our".      It seems weird because you would never use "I's" on its own but it is not on its own here - it is part of a noun phrase.   That's a rather intriguing argument. Does it hold any water? How can I get a list of all the implementations of an interface programmatically in Java? Can I do it with reflection or something like that?