I have a Dictionary&lt;string, Dictionary&lt;string, object&gt;&gt; that needs to be sorted depending on a certain value of the child dictionary. e.g {   &quot;James&quot;: {     &quot;Age&quot;:  21,     &quot;Surname&quot;: &quot;Doe&quot;,     &quot;Temp&quot;: 80.6   },   &quot;Tobi&quot;: {     &quot;Age&quot;:  26,     &quot;Surname&quot;: &quot;Doe&quot;,     &quot;Temp&quot;: 60.5   } }  The dictionary with key James and Tobi needs to be sorted depending on i.e.  the temp value. The string &quot;Temp&quot; would be given to the method to indicate the key to be sorted on. The object values type would differ depending on the context but the type would be known to the method allowing to cats the object to the correct type for comparison. Creating a specific object would not be possible for the solution as dictionary&lt;string, object&gt; represents the object properties and would differ with each implementation of the method. All child dictionaries would have the same &quot;properties&quot; so the child dictionary not having the value would not be a problem. so in plain description, a method taking in: {   &quot;James&quot;: {     &quot;Age&quot;:  21,     &quot;Surname&quot;: &quot;Doe&quot;,     &quot;Temp&quot;: 80.6   },   &quot;Tobi&quot;: {     &quot;Age&quot;:  26,     &quot;Surname&quot;: &quot;Doe&quot;,     &quot;Temp&quot;: 60.5   },   &quot;Jessica&quot;: {     &quot;Age&quot;:  18,     &quot;Surname&quot;: &quot;Samms&quot;,     &quot;Temp&quot;: 50.67   } }  and string &quot;Temp&quot; and posibily Temp type of string &quot;double&quot; that returns IEnumerable&lt;KeyValuePair&lt;string,Dictionary&lt;string,object&gt;&gt;&gt; {   &quot;Jessica&quot;: {     &quot;Age&quot;:  18,     &quot;Surname&quot;: &quot;Samms&quot;,     &quot;Temp&quot;: 50.67   },   &quot;Tobi&quot;: {     &quot;Age&quot;:  26,     &quot;Surname&quot;: &quot;Doe&quot;,     &quot;Temp&quot;: 60.5   },   &quot;James&quot;: {     &quot;Age&quot;:  21,     &quot;Surname&quot;: &quot;Doe&quot;,     &quot;Temp&quot;: 80.6   } }
I often have to sort a dictionary, consisting of keys &amp; values, by value. For example, I have a hash of words and respective frequencies, that I want to order by frequency.  There is a SortedList which is good for a single value (say frequency), that I want to map it back to the word.   orders by key, not value. Some resort to a , but is there a cleaner way?
What causes the portraits of Wizards to behave interactively? Gerund preceded by a genitive? Is this sentence actually grammatical?     You know your having a rough day when kittens don't even make you smile.   The writer of this sentence may intend to mean you're instead of your but I'm just wondering if having a gerund preceded by a genitive is considered grammatical in this case.  If the sentence above is ungrammatical, why is this sentence grammatical?      He resents your being more popular than he is.   What's the difference between these two sentence that determines one to be grammatical and the other to be not?  This is how I analyze the two sentences and I can't see the difference:   "You know it when kittens don't even make you smile" for "it" = "your having a rough day" "He resents it" for "it" = "your being more popular than he is" I've been looking all over for a proper explanation of how to delete photos from the device (nexus 5) to reclaim some space, while being sure that the pictures are still in the Google+ backup. Unfortunatley i have not found one, other than "wild claims" it works somehow, while other say it does not. Plus deleting photos via the Pictures app actually warns you (now?) that it will delete the backed up copies too. Do i have to delete them in the Gallery app?  I did delete some photos recently, and i was quite sure they ware still backed up (still showed up on the Google+ website) but looking now i see they are in the trash in the device.  Is there really no way to be able to know for sure if the pictures are backed up savely while i can delete them from the device?  Alternatively i'm also open for alternative solutions to this problem, or i just go back to the "good old copy and paste when plugging the phone". Divisibility Rule for 9 I'm working through an elementary number theory course right now and I think I've come up with a proof here but wanted some feedback on my logic.    Question:  If the sum of the digits in base 10 is divisible by 9, then the number itself is divisible by 9.    Proof: Suppose that $9|d_1+d_2+...+d_n$ then $d_1+d_2+...+d_n=0\mod9$  Now consider $d_1(10^{n-1})+d_2(10^{n-2})+...+d_{(n-1)}(10^1)+d_n(10^0)$ Each power of $10$ is equivalent to $1\mod9$   therefor  $d_1(10^{n-1})+d_2(10^{n-2})+...+d_{(n-1)}(10^1)+d_n(10^0)=(1\mod9)(d_1+d_2+...d_n)$  $9|(d_1+d_2+...d_n)$ by our assumption, thus $9|(1\mod9)(d_1+d_2+...d_n)$  Thus we have shown that if 9 divides the sum of the digits in base 10, 9 divides the number itself.    The only question I really have is whether I'm jumping the gun on my assumption concerning the powers of 10 being $1\mod 9$.  I think this is fair game here but not 100% confident.  Thanks. Why is my Wi-Fi Process eating >2GB memory As Joel points out in , in  (aka: K &amp; R), there is mention of this property of arrays in C: a[5] == 5[a]  Joel says that it's because of pointer arithmetic but I still don't understand. Why does a[5] == 5[a]? Python — How can I find the square matrix of a lower triangular numpy matrix? (with a symmetrical upper triangle) How are bones & armatures connected to the rest of a model? Let's say I'm really new to Blender, and have just barely figured out what keyframes are for. Explain a Blender skeleton to me like I'm five. Do I need to use it, and how exactly does it connect to the rest of the model? The question is :   Show that $I=\langle 2+2 i\rangle$ is not a prime ideal of $\mathbb Z[i]$. Also find the number of elements in $\mathbb Z[i]/I$ and its characteristic.  My try:  I started with elements $2, 1+i \in \mathbb Z[i]$. Clearly, the product is $0$ in the coset representation.  The part where i am struck at is the number of elements and the characteristic.  Well, $2+2i+\langle 2+2i\rangle=0+\langle 2+2i\rangle$  Can we directly write $i^2=-1$ in the coset representation? Anamorphic Perspective in Illustrator or Photoshop? Buying shares when the price goes down 2% and selling shares when it goes up 2% Chat reputation in left bar seems different than any other reputation displayed for users I know how to monitor the network interfaces on my local computer with Wireshark. But, how do I monitor the traffic flowing through my wireless access point from connected computers?  It seems like this might not be possible without some kind of special software on the wireless access point itself. Website Visible only to Registered users How are character special files and block special files different from regular files in a Unix-like system? Why are they called “character special” and “block special” respectively? Which application does the vi command open? When you type vi in the terminal, the following output is shown  ~                             VIM - Vi IMproved                                 ~                                                                              ~                               version 7.3.547                                  ~                           by Bram Moolenaar et al.                             ~           Modified by pkg-vim-maintainers@lists.alioth.debian.org              ~                 Vim is open source and freely distributable                    ~                                                                                ~                        Help poor children in Uganda!                                                                                So according to this, vi must be launching VIm. But when you type  vim it gives  aditya@aditya-desktop:~$ vim The program 'vim' can be found in the following packages:  * vim  * vim-gnome  * vim-tiny  * vim-athena  * vim-gtk  * vim-nox Try: sudo apt-get install &lt;selected package&gt;   This shows that vim is not installed. Notably man vi and man vim launch the same man pages.  So what does the vi command actually launch? How can I play sound in Java? I want to be able to play sound files in my program. Where should I look? "invalid use of incomplete type" error with partial template specialization The following code:  template &lt;typename S, typename T&gt; struct foo {    void bar(); };  template &lt;typename T&gt; void foo &lt;int, T&gt;::bar() { }   gives me the error  invalid use of incomplete type 'struct foo&lt;int, T&gt;' declaration of 'struct foo&lt;int, T&gt;'   (I'm using gcc.) Is my syntax for partial specialization wrong? Note that if I remove the second argument:  template &lt;typename S&gt; struct foo {    void bar(); };  template &lt;&gt; void foo &lt;int&gt;::bar() { }   then it compiles correctly. Regular Expression to split on spaces unless in quotes I would like to use the .Net Regex.Split method to split this input string into an array. It must split on whitespace unless it is enclosed in a quote.  Input:  Here is "my string"&nbsp;&nbsp;&nbsp;&nbsp;it has "six&nbsp;&nbsp;matches"  Expected output:   Here is my string it has six&nbsp;&nbsp;matches   What pattern do I need? Also do I need to specify any RegexOptions? Ckeditor toolbar not entirely showing up I have just moved my site from local machine to production, the wysiwyg editor based on ckeditor no longer show the complete toolbar. I have a minimal list of element. Can someone help, am trying everything, edit profile, check if all files are uploaded, i don't see any problem !