How can you explain this Python program's output?
What is the difference between class and instance attributes?
Php - regular expression to check if the string has chinese chars PDF editing within Apex/Visualforce I'd like to write something in the shape of this "coat of arms".    I'd like to have the text filling the coat but with a hole roughly in the shape of the sword. I know there is the \shapepar command to create paragraph shapes so I tried to , a patch for XFig that allows you to draw the shape you want but it never worked on my computer (Mac OS X). I also know I can build the shape by myself with shapepar syntax but it seems really complicated and I don't think I'll make a lot of shapes. So if anybody has ShapePatch working on his computer or knows shapepar syntax very well, could he give me the code? For all infinite cardinals $\kappa, \ (\kappa \times \kappa, <_{cw}) \cong (\kappa, \in).$ I don't understand the proof to the a/m claim. How we know that $\eta &lt; \kappa$ and $(\alpha,\beta)&lt;_{cw} (0, \eta) $ and hence $h: \mu \to \eta \times \eta$ is injective? Appreciate if anyone could advise.  Here is an excerpt of the proof:  For an infinite ordinal $\kappa,$ the canonical well-ordering of $\kappa \times \kappa,$ denoted by $&lt;_{cw}$ is defined as follows: $(\alpha_1, \beta_1)&lt;_{cw} &lt; (\alpha_2, \beta_2)$ iff either one of the following holds.  $(1): \max\{\alpha_1,\beta_1\} &lt; \max\{\alpha_2,\beta_2\}$  $(2): \max\{\alpha_1,\beta_1\} =\max\{\alpha_2,\beta_2\}$ and $\alpha_1&lt;\alpha_2$   $(3): \max\{\alpha_1,\beta_1\} =\max\{\alpha_2,\beta_2\}$ and $\alpha_1 = \alpha_2$ and $\beta_1 &lt; \beta_2.$  Claim: For all infinite cardinals $\kappa, (\kappa \times \kappa, &lt;_{cw}) \cong (\kappa, \in).$  Proof: (It has been show that it is true for $\kappa = \omega$) Assume there is a counterexample  $\kappa.$ Let $A= \{\lambda \in \kappa + 1| \lambda\geq \omega \ is \ a \ cardinal \ and \ (\lambda \times \lambda, &lt;_{cw}) \not\cong (\lambda, \in)\}.$ Then, $\kappa \in A.$ Let $\mu$ be least element of $A.$ Thus, $\mu &gt; \omega$ and for all $\lambda,$ if $\omega \leq \lambda &lt; \mu$ and $\lambda$ is a cardinal, then $(\lambda \times \lambda, &lt;_{cw}) \cong (\lambda, \in).$  By Comparability theorem, $(\mu, \in)$ is isomorphic to initial segment of $(\mu \times \mu, &lt;_{cw})$ since $|\mu \times \mu| \geq \mu$ and $\mu$ is cardinal. Let $(\alpha, \beta) \in \mu \times \mu$ such that $(\mu, \in)$ is isomorphic to initial segment of $(\mu \times \mu, &lt;_{cw})$ given by $(\alpha, \beta).$ Let $h$ be the isomorphism. Let $\eta= \max\{\alpha, \beta\}+ \omega.$ Then $\eta &lt; \kappa$ and $(\alpha,\beta)&lt;_{cw} (0, \eta).$ HENCE, $h: \mu \to \eta \times \eta$ is injective. What is an unsigned char? In C/C++, what an unsigned char is used for? How is it different from a regular char? Deleting array elements in JavaScript - delete vs splice What is the difference between using  on the array element as opposed to using ?   For example:  myArray = ['a', 'b', 'c', 'd'];  delete myArray[1]; //  or myArray.splice (1, 1);   Why even have the splice method if I can delete array elements like I can with objects? What is a good use case for static import of methods? Just got a review comment that my static import of the method was not a good idea. The static import was of a method from a DA class, which has mostly static methods. So in middle of the business logic I had a da activity that apparently seemed to belong to the current class:  import static some.package.DA.*; class BusinessObject {   void someMethod() {     ....     save(this);   } }    The reviewer was not keen that I change the code and I didn't but I do kind of agree with him. One reason given for not static-importing was it was confusing where the method was defined, it wasn't in the current class and not in any superclass so it too some time to identify its definition (the web based review system does not have clickable links like IDE :-) I don't really think this matters, static-imports are still quite new and soon we will all get used to locating them.  But the other reason, the one I agree with, is that an unqualified method call seems to belong to current object and should not jump contexts. But if it really did belong, it would make sense to extend that super class.  So, when does it make sense to static import methods? When have you done it? Did/do you like the way the unqualified calls look?  EDIT: The popular opinion seems to be that static-import methods if nobody is going to confuse them as methods of the current class. For example methods from java.lang.Math and java.awt.Color. But if abs and getAlpha are not ambiguous I don't see why readEmployee is. As in lot of programming choices, I think this too is a personal preference thing.   Thanks for your response guys, I am closing the question. Where to or how to ask "Best of" Questions for what software tools to use I am wondering where is a good place or how is a good way to ask a question on what software tools to use for a specific task.  A lot of the time when searching for information on these types of problems stackoverflow comes up with the top and actually useful discussions and answers, but the question is locked.  I completely understand the point of discouraging "best of" or list questions as discussed in this question () and agree they often aren't constructive enough to justify the effort in moderating them.  What I am wondering is where is the right place to have a discussion like this? Stackoverflow has a good and active community so perhaps there is another section or related site I can ask less specific questions. And I do find some value in reading people's opinions, even if subjective on issues like this.  Here are some examples of the kind of questions I mean:    and   First results in google when searching for those subjects and some useful discussion.  Perhaps asking a question like this but with a strict and detailed specification it might be considered a valid and reasonable question to ask on stackoverflow; perhaps it's just a case of re-thinking how to ask a question. Or perhaps there's a more relevant place for this kind of discussion. Please let me know what you think. "A friend of my father" vs. "a friend of my father's" — which one is right? Why? I have seen them both in my reference book, which is written by a native speaker. I wonder why there are two different phrases to describe the same meaning and am looking forward to some reasonable details to explain why this is so. In a raster layer's Style Properties, I can choose pseudocolor render type, and choose a color ramp and classify the raster.      However, when I click the 'Apply' button, or click 'OK', the visualization of the raster never changes.  I was able to output a 'colorized' version of the same raster using GRASS plugin.  I also reinstalled QGIS 2.8, and was able to adjust and see a raster stylings using the steps I outlined above.  So, can anyone confirm this as an issue, or confirm that there's a mistake somewhere in my process?  I should note that I'm on a Mac, 10.10.4, and I'm using the QGIS provided by , 2.10.1-1 .  Update 1: Here's a screenshot of the rest of my settings.      I have Grayscale set to off in the Style setting.  Also, I don't believe grayscale/color-blind Preview is available on the Mac version of QGIS.  They're does't appear to be the option where it , in the Menu Bar under View / Preview / Photocopy (grayscale) etc.  Either way-- I added a shapefile to show color.  Update 2: I've experimented with setting color interpolation to discrete, linear, and exact, but still am not able stylize using Singleband pseudocolor.  I've also confirmed that the 'Render' box on the the main map view is checked.  Also, I am able to adjust Color Rendering settings, like Hue, Blending Mode, etc., and see the results when clicking 'Apply' or 'OK'.  Update 3: As other Mac users are confirming this, I think it may be a bug. I've created a bug report at the official . Cut strokes from other shapes via pathfinder TP-LINK TL-WN823N Unable to connect to network I have purchased a TP-LINK TL-WN823N (EU) V2.0 device, which is a USB device that should work as a Network Interface Card, allowing me to connect my computer to wireless networks. Unfortunately, I am unable to find any wireless networks using this device using either wicd or network-manager (no networks appear in the list of networks supplied by either application).  A CD came with the device claiming "Linux support". The CD contained a URL to a corrupted archive file for downloading installation resources. I try to mask my immense frustration.  Here is the additional dmesg output I receive when I connect the device to my computer (similar content is present when I boot the computer with the device connected):  [17096.009912] usb 2-1.2: new high-speed USB device number 4 using ehci-pci [17096.103501] usb 2-1.2: New USB device found, idVendor=2357, idProduct=0109 [17096.103513] usb 2-1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=3 [17096.103527] usb 2-1.2: Product: 802.11n NIC [17096.103529] usb 2-1.2: Manufacturer: Realtek [17096.103530] usb 2-1.2: SerialNumber: 00e04c000001   This is my lsusb, where the offending device corresponds to Bus 002 Device 004:  Bus 002 Device 003: ID 0a5c:5800 Broadcom Corp. BCM5880 Secure Applications Processor Bus 002 Device 004: ID 2357:0109   Bus 002 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 001 Device 004: ID 0c45:6433 Microdia  Bus 001 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub   As lsusb -v:   It seems the device is working to me, but no new interface is found in 'ifconfig':  docker0   Link encap:Ethernet  HWaddr 02:42:6e:bf:92:16             inet addr:172.17.0.1  Bcast:0.0.0.0  Mask:255.255.0.0           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:0            RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)  enp0s31f6 Link encap:Ethernet  HWaddr 30:5a:3a:e1:96:b1             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:16 Memory:df200000-df220000   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:65536  Metric:1           RX packets:412 errors:0 dropped:0 overruns:0 frame:0           TX packets:412 errors:0 dropped:0 overruns:0 carrier:0           collisions:0 txqueuelen:1           RX bytes:31876 (31.8 KB)  TX bytes:31876 (31.8 KB)   Running 'lshw -class network' as root contains only information about the 'enp0s31f6' interface.  Additionally for sanity, my 'uname -a':  Linux home-z170a-ubuntu 4.4.0-22-generic #39=Ubuntu SMP Thu May 5 16:53:32 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux   I am using Ubuntu 16.04.  My questions are:   Why are no networks present in the list for wicd or network-manager? Why is there no additional network interface created when I plug in the USB device? Is it possible to create this network interface?   Thanks for reading. Adding other css files to wp_head I have a requirement to implement an "Unsaved Changes" prompt in an ASP .Net application.  If a user modifies controls on a web form, and attempts to navigate away before saving, a prompt should appear warning them that they have unsaved changes, and give them the option to cancel and stay on the current page.  The prompt should not display if the user hasn't touched any of the controls.  Ideally I'd like to implement this in JavaScript, but before I go down the path of rolling my own code, are there any existing frameworks or recommended design patterns for achieving this?  Ideally I'd like something that can easily be reused across multiple pages with minimal changes. I run windows 7. I run a Minecraft server, but I can only host around 9 players before lag appears.   I heard that Ubuntu can run a server with much better performance than Windows 7. I kind of like the whole idea of Ubuntu, but I don't want to change my OS to Unix or anything else.  Basically, my question is, does running a server (specifically and Minecraft server) run easier and faster on a Ubuntu server? On top of that, how would one set that up? About the complex nature of the wave function? 1.  Why is the wave function complex? I've collected some layman explanations but they are incomplete and unsatisfactory. However in the book by Merzbacher in the initial few pages he provides an explanation that I need some help with: that the de Broglie wavelength and the wavelength of an elastic wave do not show similar properties under a Galilean transformation. He basically says that both are equivalent under a gauge transform and also, separately by Lorentz transforms. This, accompanied with the observation that $\psi$ is not observable, so there is no "reason for it being real". Can someone give me an intuitive prelude by what is a gauge transform and why does it give the same result as a Lorentz tranformation in a non-relativistic setting? And eventually how in this "grand scheme" the complex nature of the wave function becomes evident.. in a way that a dummy like me can understand.  2.   A wavefunction can be thought of as a scalar field (has a scalar value in every point ($r,t$) given by $\psi:\mathbb{R^3}\times \mathbb{R}\rightarrow \mathbb{C}$ and also as a ray in Hilbert space (a vector). How are these two perspectives the same (this is possibly something elementary that I am missing out, or getting confused by definitions and terminology, if that is the case I am desperate for help ;)   3.   One way I have thought about the above question is that the wave function can be equivalently written in $\psi:\mathbb{R^3}\times \mathbb{R}\rightarrow \mathbb{R}^2 $ i.e, Since a wave function is complex, the Schroedinger equation could in principle be written equivalently as coupled differential equations in two real functions which staisfy the Cauchy-Riemann conditions. ie, if $$\psi(x,t) = u(x,t) + i v(x,t)$$ and $u_x=v_t$ ; $u_t = -v_x$ and we get $$\hbar \partial_t u  = -\frac{\hbar^2}{2m} \partial_x^2v + V v$$ $$\hbar \partial_t v  = \frac{\hbar^2}{2m} \partial_x^2u - V u$$ (..in 1-D) If this is correct what are the interpretations of the $u,v$.. and why isn't it useful. (I am assuming that physical problems always have an analytic $\psi(r,t)$). Do fixtures trigger model callbacks? We learned in Thor: Ragnarok that Mjolnir is only a focus for Thor's power, not the source. If so, when a worthy​ being lifts Mjolnir and gains "the power of Thor", where are they getting the power from? How can you detect if users have created sock puppet accounts? How many users have created more than one profile on SO to vote themselves on their other original profile? There are some benefits when you have more reputation and sometimes you don't want a single -1 vote on your question or answer. In this case you may have an extra account to convert that -1 vote into 0 vote and  upvote for each of your questions and answers to gain reputation. I think it is not a good thing to do as a good developer.  Is there any way to recognize this situation? I think there should be some stats in each user's profile about how many votes are posted by each user on him/her or something like that.  So how many users have more than one profile? How to handle this situation? I have not created one yet but............ I don't think so :) Ralink RT3290 bluetooth adapter does not work, but wifi works perfectly.