How to find all duplicate from a List?
C# LINQ find duplicates in List
Why {are you / you are} making noise? Where can I get a device with 'Ubuntu for phones' pre-installed? The pronunciation of words which begins 'con' and 'com' How to find out why "context is incorrect"? Why does the weighing balance restore when tilted and released What's the difference between $\equiv$ and $\leftrightarrow$ in a formal proof? Apply empty style to the entire bibliography Is there a number whose absolute value is negative? Playing a remote movie on the remote computer I have two computers (a desktop and a laptop) running linux connected to my local area network. I like to ssh from my laptop over to my desktop and run programs there, and sometimes listen to music on my desktop, which is connected to my stereo system. Lately, I've been wanting to play movies on the desktop and desktop screen, but cue them from my laptop across the room.   Unfortunately, I cannot play a movie in the current X session running on my Desktop on from my laptop. What is odd about this is that I can listen to the audio coming from the speakers that are hooked up to my desktop, by playing the audio files over ssh! This tells me that there must be a way to send the movie to that Xsession, from the ssh shell that I am connected to.  Does anyone have any ideas about this? Converting date to specified format and two date comparisions How to best determine if a bike will fit without riding it Cleaning Contaminated Disc Rotors I've had an eternal struggle with my current bike over brake contamination. The levers and calipers are shimano ultegra r8000, so the latest and (almost) greatest.  I first noticed it when I took it to a repair shop (i no longer use) for a bleed, it came back and the front brake would squeal like crazy and at low speeds had little to no braking force. You can stop from speed but then struggle to come to a halt without using your foot.  At around 2000 miles I tried to replace the brake pads, when I took them out they were black with grime on both sets (front &amp; back), not to mention worn down to the metal. I replaced them with the L04C sintered pads, gave the callipers a good cleaning with a towel (no chemicals) and fitted the new set.  Annoyingly all of my braking issues are back, now I probably should have cleaned the rotors, I simply used some muc off disc brake cleaner on them. I would like to know the best way to clean the rotors, I've inspected the pads and they are looking fairly black now, with plenty of tread left. I'm going to abandon these pads and fit a new set. For the rotors I plan to completely remove them from the wheels (they are center lock fitted) and try and treat them off the bike, what is the best way to fully clean them? They have plenty of wear left in them but you can see these black grooves in them, and plenty of muck on the back that I struggle to get off.  Below are images of the rotors after soaking them in disc brake cleaners, waiting and then wiping them down with a clean, microfiber towel.   Front Wheel Outside Rotor   Front Wheel Inside Rotor - note the increased dirt on this side  Looking at ways people clean their disc rotors, I've seen plenty of suggestions that I would need to burn the contaminants off the discs. Would the best approach be to remove them and use a blowtorch, should I soak them in some nasty chemicals overnight before I try to heat them? Do I try baking them in the oven?  And finally, what is the best way to prevent the brakes from becoming contaminated in the future? it's really off putting when they squeal and don't perform how I'd expect because it means I'm more reserved whilst out riding on the bike, leading to reduced time riding around outside. I commute on this bike (50 miles a week) and then ride about 50 on the weekends also, so it see's it's fair share of road use. I tend to wash it once after my big ride on saturdays and will rinse it off if it's been raining, any day that occurs (since I live in north east england, the acid rain..). I've owned disc brake bikes before and never had half the issues I've had with this, I had a cheap trek with tektro brakes and the brakes were sharper and never had any issues with contamination whatsoever (i did around 500 miles on that bike before a motorist happened).  Thanks for any and all advice :) Is there a way to make a fullscreen on VirtualBox? I tried many ways to make a bigger screen in VirtualBox because I do not like the small size of the guest window? Is there is a way to make it big? Let $A,B$ be two sets. The  states that if there is an injection $f\colon A\to B$ and an injection $g\colon B\to A$, then there exists a bijection $h\colon A\to B$.  I was wondering whether the following statements are true (maybe by using the AC if necessary):   Suppose $f \colon A\to B$ and $g\colon B\to A$ are both surjective, does this imply that there is a bijection between $A$ and $B$. Suppose either $f\colon A\to B$ or $g\colon  A\to B$ is surjective and the other one injective, does this imply that there is a bijection between $A$ and $B$. What do we mean by hyperparameters? Can anyone give me full details about what we mean by hyperparameters, and what in the Dirichlet distribution are called hyperparameters? A practice example for the estimation of those parameters would also be useful. Are there any downsides to passing structs by value in C, rather than passing a pointer? Are there any downsides to passing structs by value in C, rather than passing a pointer?  If the struct is large, there is obviously the performancd aspect of copying lots of data, but for a smaller struct, it should basically be the same as passing several values to a function.  It is maybe even more interesting when used as return values. C only has single return values from functions, but you often need several. So a simple solution is to put them in a struct and return that.  Are there any reasons for or against this?  Since it might not be obvious to everyone what I'm talking about here, I'll give  a simple example.  If you're programming in C, you'll sooner or later start writing functions that look like this:  void examine_data(const char *ptr, size_t len) {     ... }  char *p = ...; size_t l = ...; examine_data(p, l);   This isn't a problem. The only issue is that you have to agree with your coworker in which the order the parameters should be so you use the same convention in all functions.  But what happens when you want to return the same kind of information? You typically get something like this:  char *get_data(size_t *len); {     ...     *len = ...datalen...;     return ...data...; } size_t len; char *p = get_data(&amp;len);   This works fine, but is much more problematic. A return value is a return value, except that in this implementation it isn't. There is no way to tell from the above that the function get_data isn't allowed to look at what len points to. And there is nothing that makes the compiler check that a value is actually returned through that pointer. So next month, when someone else modifies the code without understanding it properly (because he didn't read the documentation?) it gets broken without anyone noticing, or it starts crashing randomly.  So, the solution I propose is the simple struct  struct blob { char *ptr; size_t len; }   The examples can be rewritten like this:  void examine_data(const struct blob data) {     ... use data.tr and data.len ... }  struct blob = { .ptr = ..., .len = ... }; examine_data(blob);  struct blob get_data(void); {     ...     return (struct blob){ .ptr = ...data..., .len = ...len... }; } struct blob data = get_data();   For some reason, I think that most people would instinctively make examine_data take a pointer to a struct blob, but I don't see why. It still gets a pointer and an integer, it's just much  clearer that they go together. And in the get_data case it is impossible to mess up in the way I described before, since there is no input value for the length, and there must be a returned length. Base-b Representation of an Integer: Why can I make the assumption about number of terms in expansions in uniqueness part?   Reading the book of Koshy I have come across the below theorem. It states that I can write any integer $N$ in a base $b\ge2$ representation $N=a_kb^k+...+a_1b+a_0$ such that $0\le a_i&lt;b$, $a_k \neq 0$ for some $k\ge0$.  In the uniqueness part, why can I assume the expansions contains the same number of terms ? I must prove that all expansions of $N$ equal the one in the theorem, but if I add terms to the expansion by zero coefficients, well, then the expansion is not in the proper form anymore ? (the greatest term in the expansion is $0$ if I add zero coefficients) .  Can someone help clear this out ?     Why can I assume the expansions contain the same number of terms ? If I add terms to the expansion, well then I've violated the form of the expansion ? Eclipse CDT - Copy static resource file to bin_dir This is one of the BibTex entries giving the problem:  @ARTICLE{2015ApJ...808L..36B,    author = {{Bonnivard}, V. and {Combet}, C. and {Maurin}, D. and {Geringer-Sameth}, A. and      {Koushiappas}, S.~M. and {Walker}, M.~G. and {Mateo}, M. and      {Olszewski}, E.~W. and {Bailey}, III, J.~I.},     title = "{Dark Matter Annihilation and Decay Profiles for the Reticulum II Dwarf Spheroidal Galaxy}",   journal = {\apjl}, archivePrefix = "arXiv",    eprint = {1504.03309},  primaryClass = "astro-ph.HE",  keywords = {dark matter, galaxies: dwarf, galaxies: individual: Reticulum II, gamma rays: galaxies, methods: statistical, stars: kinematics and dynamics},      year = 2015,     month = aug,    volume = 808,       eid = {L36},     pages = {L36},       doi = {10.1088/2041-8205/808/2/L36},    adsurl = {http://adsabs.harvard.edu/abs/2015ApJ...808L..36B},   adsnote = {Provided by the SAO/NASA Astrophysics Data System} }   and corresponding bbl file giving the error at compilation is  \bibitem{2009ApJ...697.1071A} {\sc W.~B. {Atwood}, A.~A. {Abdo}, M.~{Ackermann}, W.~{Althouse},   B.~{Anderson}, M.~{Axelsson}, L.~{Baldini}, J.~{Ballet}, D.~L. {Band},   G.~{Barbiellini}, and et~al.} \newblock {\bf {The Large Area Telescope on the Fermi Gamma-Ray Space Telescope   Mission}}. \newblock {\em \apj}, {\bf 697}:1071--1102, June 2009.   My guess is that Kile doesn't like references of the form 2015ApJ...808L..36B since these are the only ones giving the error.    Can somebody hint me to the problem in this? Thank you very much network manager says "device not managed" I used to be able to share my network connection by editing the Auto Eth0 to share with other computers in the Ipv4 section and now I upgraded my laptop to 11.10 .  Now are there no wired connections in the network manager. When I click my connections applet at the top of the tray it also says wired device not managed!  when I type ifconfig -a  daniella@daniella-1001HA:~$ ifconfig -a eth0      Link encap:Ethernet  HWaddr 90:e6:ba:83:d6:fc             UP BROADCAST MULTICAST  MTU:1500  Metric:1           RX packets:0 errors:0 dropped:0 overruns:0 frame:0           TX packets:0 errors:0 dropped:0 overruns:0 carrier:0           collisions:0 txqueuelen:1000            RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)           Interrupt:45   eth0:avahi Link encap:Ethernet  HWaddr 90:e6:ba:83:d6:fc             inet addr:169.254.13.40  Bcast:169.254.255.255  Mask:255.255.0.0           UP BROADCAST MULTICAST  MTU:1500  Metric:1           Interrupt:45   lo        Link encap:Local Loopback             inet addr:127.0.0.1  Mask:255.0.0.0           inet6 addr: ::1/128 Scope:Host           UP LOOPBACK RUNNING  MTU:16436  Metric:1           RX packets:0 errors:0 dropped:0 overruns:0 frame:0           TX packets:0 errors:0 dropped:0 overruns:0 carrier:0           collisions:0 txqueuelen:0            RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)  wlan0     Link encap:Ethernet  HWaddr 00:25:d3:90:43:41             inet addr:192.168.0.6  Bcast:192.168.0.255  Mask:255.255.255.0           inet6 addr: fe80::225:d3ff:fe90:4341/64 Scope:Link           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1           RX packets:12881 errors:0 dropped:0 overruns:0 frame:0           TX packets:12867 errors:0 dropped:0 overruns:0 carrier:0           collisions:0 txqueuelen:1000            RX bytes:8851081 (8.8 MB)  TX bytes:2343199 (2.3 MB)