This question was marked as duplicate of . I am not asking how to create enumerations, I'm asking how to create constants, and that is the difference between the questions.  This question was marked as duplicate of . While the answers do explain how to create constants in python they don't explain how to create them in Enum like style, which is what my question is asking for.  I need to create constants in my python code. I don't want the user to be able to modify them. I found , but it is not exactly what I need. I need to be be able to use them just like enums, without creating and instance.  For example:  class MyConstClass(object):     Const0 = 0     Const1 = 1     Const2 = 2  myfunc(MyConstClass.Const0) MyConstClass.Const1 = 20 # Raise an exception   I also don't want to create a module, just like it is done   Is there a way to do it?
I'm mainly a C# developer, but I'm currently working on a project in Python.  How can I represent the equivalent of an Enum in Python?
How to view the moderators here in MSE? I  am able to view the Stack Overflow site moderators by clicking on this    But when I search the same in meta.stackexchange, it does not display the site moderators.    The below message is displayed      We believe moderation starts with the community itself, so in addition   to privileges earned through reputation, we periodically hold   democratic moderator elections.      Please see A Theory of Moderation for information on our moderation   philosophy   My Questions:   Are there restrictions to view the site moderators in meta.Stackexchange? How does the above message make sense when viewing the moderators? Can someone explain this to me? Possible (but not serious) glitch in close/reopen I just had one of my questions closed. (Hey - it happens to everyone) When I clicked on reopen - lo and behold - it worked. I cast a reopen vote!  Is this a glitch? I know we need 4 more votes anyway but still...  And no  tag please :) $f(z)$ and $\overline{f(\overline{z})}$ simultaneously holomorphic Bluetooth is on but can't find or be found by any other devices.  Output of sudo service bluetooth status:  ● bluetooth.service - Bluetooth service    Loaded: loaded (/lib/systemd/system/bluetooth.service; enabled; vendor preset: enabled)    Active: active (running) since ხუთ 2015-06-04 22:33:18 GET; 13min ago  Main PID: 26678 (bluetoothd)    CGroup: /system.slice/bluetooth.service            └─26678 /usr/sbin/bluetoothd -n  ივნ 04 22:39:14 Rangoo bluetoothd[26678]: Endpoint registered: sender=:1.63 path=/MediaEndpoint/BlueZ4/HFPAG ივნ 04 22:39:14 Rangoo bluetoothd[26678]: Endpoint registered: sender=:1.63 path=/MediaEndpoint/BlueZ4/HFPHS ივნ 04 22:39:14 Rangoo bluetoothd[26678]: Endpoint registered: sender=:1.63 path=/MediaEndpoint/BlueZ4/A2DPSource ივნ 04 22:39:14 Rangoo bluetoothd[26678]: Endpoint registered: sender=:1.63 path=/MediaEndpoint/BlueZ4/A2DPSink ივნ 04 22:39:14 Rangoo bluetoothd[26678]: bluetoothd[26678]: Endpoint registered: sender=:1.63 path=/MediaEndpoint/BlueZ4/HFPAG ივნ 04 22:39:14 Rangoo bluetoothd[26678]: bluetoothd[26678]: Endpoint registered: sender=:1.63 path=/MediaEndpoint/BlueZ4/HFPHS ივნ 04 22:39:14 Rangoo bluetoothd[26678]: bluetoothd[26678]: Endpoint registered: sender=:1.63 path=/MediaEndpoint/BlueZ4/A2DPSource ივნ 04 22:39:14 Rangoo bluetoothd[26678]: bluetoothd[26678]: Endpoint registered: sender=:1.63 path=/MediaEndpoint/BlueZ4/A2DPSink ივნ 04 22:39:14 Rangoo bluetoothd[26678]: Adapter /org/bluez/26678/hci0 has been enabled ივნ 04 22:39:14 Rangoo bluetoothd[26678]: bluetoothd[26678]: Adapter /org/bluez/26678/hci0 has been enabled   Output of lsusb:  Bus 003 Device 005: ID 0a5c:21d7 Broadcom Corp. BCM43142 Bluetooth 4.0   How can I fix it? How to fix Permission Denied (Public key) error? While trying to communicate between my desktop Ubuntu 12.10 and Fedora 19 desktop, I am facing the error of Permission Denied (Public key). I am able to login through ssh from fedora to Ubuntu, but not vice-versa. I even performed telnet on both machines via port 22 and both machines are listening, but not through ssh. What to do? Any idea?  My sshd_config file is as follows:  # Package generated configuration file # See the sshd_config(5) manpage for details  # What ports, IPs and protocols we listen for Port 22 # Use these options to restrict which interfaces/protocols sshd will bind to #ListenAddress :: #ListenAddress 0.0.0.0 Protocol 2 # HostKeys for protocol version 2 HostKey /etc/ssh/ssh_host_rsa_key HostKey /etc/ssh/ssh_host_dsa_key HostKey /etc/ssh/ssh_host_ecdsa_key #Privilege Separation is turned on for security UsePrivilegeSeparation yes  # Lifetime and size of ephemeral version 1 server key KeyRegenerationInterval 3600 ServerKeyBits 768  # Logging SyslogFacility AUTH LogLevel INFO  # Authentication: LoginGraceTime 120 PermitRootLogin yes StrictModes yes  RSAAuthentication yes PubkeyAuthentication yes #AuthorizedKeysFile    %h/.ssh/authorized_keys  # Don't read the user's ~/.rhosts and ~/.shosts files IgnoreRhosts yes # For this to work you will also need host keys in /etc/ssh_known_hosts RhostsRSAAuthentication no # similar for protocol version 2 HostbasedAuthentication no # Uncomment if you don't trust ~/.ssh/known_hosts for RhostsRSAAuthentication #IgnoreUserKnownHosts yes  # To enable empty passwords, change to yes (NOT RECOMMENDED) PermitEmptyPasswords no  # Change to yes to enable challenge-response passwords (beware issues with # some PAM modules and threads) ChallengeResponseAuthentication no  # Change to no to disable tunnelled clear text passwords PasswordAuthentication yes  # Kerberos options #KerberosAuthentication no #KerberosGetAFSToken no #KerberosOrLocalPasswd yes #KerberosTicketCleanup yes  # GSSAPI options GSSAPIAuthentication no GSSAPICleanupCredentials yes  X11Forwarding yes X11DisplayOffset 10 PrintMotd no PrintLastLog yes TCPKeepAlive yes #UseLogin no  #MaxStartups 10:30:60 #Banner /etc/issue.net  # Allow client to pass locale environment variables AcceptEnv LANG LC_*  Subsystem sftp /usr/lib/openssh/sftp-server  # Set this to 'yes' to enable PAM authentication, account processing, # and session processing. If this is enabled, PAM authentication will # be allowed through the ChallengeResponseAuthentication and # PasswordAuthentication.  Depending on your PAM configuration, # PAM authentication via ChallengeResponseAuthentication may bypass # the setting of "PermitRootLogin without-password". # If you just want the PAM account and session checks to run without # PAM authentication, then enable this but set PasswordAuthentication # and ChallengeResponseAuthentication to 'no'. UsePAM yes   This is sshd_config of ubuntu system. Trying to remember a book about a human male travelling to alien planet I listened to this on audiobook and it was great.  The premise was a human ends up travelling to an alien planet. The aliens have a perimeter to their 'base' that is under constant attack from the planet's animals. It is revealed towards the end that there is some sort of signal being transmitted that is making all the animals and plant life attack a certain point on the planet (where the aliens are).   Other major plot points I remember: The human traveller falls in love with an alien. The aliens have a sort of virtual training environment that simulates life outside the perimeter, where plants attack you etc. There is a secondary alien group that the human ends up with, and although they are rivals to other group, they have a trade set up.   Any help much appreciated! Thanks. If a person was sitting on a craft that has accelerated to near light speed speed from Earth (e.g. 99.999% of light speed) would there be any impact on his or her human biology due to relativistic effects on mass, time and distance?    For example, would the heart still be able to pump blood effectively if the relativistic mass of the blood has increased?    Or would accelerating the blood a bit further towards light speed requires more energy than when stationary on earth? How can I make Ubuntu 18.04 / 18.10 desktop use Unity (be like Ubuntu 14.04)? I recently installed Ubuntu 18.04 and I'm not keen on the desktop environment. I want the desktop env. I used to have in Ubuntu 14.04. How can I get it?  I've attempted to use , but when I try to install the Unity's 7.2.5 version using the command:  apt install unity=7.2.5   it gives me   E: Version '7.2.5' for 'unity' was not found   For sure I need to add a PPA for this, but which one!? What are Thumbs.db files for? How can I prevent them from being created? clerics have the ability  (PHB, p. 62):     When a creature within 5 feet of you that you can see hits you with an attack, you can use your reaction to cause the creature to make a Dexterity saving throw. The creature takes 2d8 lightning or thunder damage (your choice) on a failed saving throw, and half as much damage on a successful one.   It doesn't specify what the DC of the saving throw is.   I assume it uses the spell save DC, even though it technically isn't a spell?     Spell save DC = 8 + your proficiency bonus + your Wisdom modifier What's the fixed size of the suggested edit queue? We know that Stack Overflow has a suggested edit queue, visible to the users who have the  privilege. Someone said the queue has a fixed size.  What's the fixed size of the suggested edit queue?  Is it often that the queue gets filled up and users can no longer suggest edits? It  to disable internet search results in start menu searches before the Windows 10 Creators Update, but I've just clean installed a new Windows 10 Pro image and that setting is gone. Is there some way to disable it through editing the registry/etc? probability that exactly two accidents happen in any day of a week if 7 accidents happen in a week If 7 accidents happen in a week, what is the probability that exactly 2 accidents happen in any day of the week.  I tried to work it this way.  2 accidents out of 7 can be taken in ${7}\choose{2}$$= 21$.  Now this can happen in any of the 7 days, so we have $7 \times 21$.  Now, the remaining 5 can happen in $6^5$ ways.  So the probability is  $\frac{7\times 21 \times 6^5}{7^7} = \frac{3 \times 6^5}{7^5}$   But this gives me a value greater than 1.   I know I am doing something wrong.  Can anyone help me ? .NET obfuscation tools/strategy How do I copy Word tables into Excel without splitting cells into multiple rows? I have data in a Word table that includes line and paragraph breaks. When I copy the data into Excel, it splits each line and paragraph I want into multiple cells. How do I copy the data to Excel and keep the breaks? Are there areas of mathematics (current or future) that cannot be formalized in set theory? I often read that ZFC can formalize "most" of everyday mathematics, but I could never find an example which it cannot. The closest I got is differential geometry (DF), where some article mentions that the translation from concepts of DF into set theory would render it almost "meaningless", in the sense that any intuitions one could have would be lost in the translation. So, if I didn't misunderstand, at least in theory, the translation could be done, so that a future AI machine could prove theorems of differential geometry using set theory. On the other hand, the Stanford Encyclopedia of  Philosophy states that "all of mathematics can be reduced to a formal system of set theory"().   So, the questions are:    Is there any current area of mathematics that could be not formalized within set theory? If so, which ones? and  Is there any reason to think that every math of the future will be always formalizable in set theory? any references to read on the subject are welcomed!   Clarification: by set theory I am not restricting to ZFC, but to any flavor of it, including all additional axioms you want (about large cardinals or any kind) Is there a rule of thumb for objective questions asked out of curiosity? Isaac Moses, the patriarch of Mi Yodeya, :  [...] the general Stack Exchange directive, expressed in the uneditable part of that section of the About page, to &quot;Focus on questions about an actual problem you have faced. Include details about what you have tried and exactly what you are trying to do.&quot; In fact, while this directive is perfect for the behemoth programming site that Stack Exchange grew out of, it doesn't fit very well for any of the more intellectually-oriented, rather than practically-oriented sites. [...]  This is something that's bugged me for a while, and ended up prompting a discussion between Anna, Aarthi and me. The gist of it: is there any simple test that can be used to identify answerable questions asked in good faith when the &quot;problem to be solved&quot; is... simple curiosity? Obviously, this is something that sites like  and  have had to contend with for some time, but now and then such questions pop up even on sites where folks are generally trying to solve real problems. While a potentially interesting thought experiment, . Strictly-speaking, problems like that fail the  test. And yet, I would keep that question simply because I learned something useful from the answers − not necessarily something I would ever apply to socks mind you, but certainly something I might apply to similar problems. I don't believe the question was asked in bad faith or for mindless social fun; yet, I have a bit of trouble stretching the definition of &quot;based on actual problems&quot; to contain it. Obviously, the fact that we're hosting a growing number of sites dedicated mostly or entirely to intellectual curiosity makes this something of a rhetorical question. The &quot;actual problems&quot; part of the FAQ was added specifically to draw a line between good and bad  − heading off  and their ilk. But it's a pretty damn good litmus test, and if it's ok to ignore it for some questions − or particularly for  − then what should stand in its place? Show that $\cot \frac{\pi}{2m}\cot \frac{2\pi}{2m}\cot \frac{3\pi}{2m}...\cot \frac{(m-1)\pi}{2m}=1$ How to derive addition of velocities without the Lorentz transformation? I can't destroy blocks in Minecraft Creative Mode (singleplayer)