I am trying to make a feature in my survival minigame where every once and a while a random player is teleported to a hidden room via command blocks. Inside, players will be allowed to hit one button, then be teleported back to the main arena. Each button gives you different items, and one I want to have is to have it give you tipped arrows (like harming potion arrows). But, my command isn't working. Here is what I got:  /give @p arrow 1 0 {Potion:"harming"}  I found the last part . What is wrong with the command? As I said, I am on Windows-10 version (v1.1.0).
This question was recently split into different questions for each workaround. See   meta posts for more information.   Can you use NBT tags in commands? I’ve tried commands that normally work in Java Edition like: give @s minecraft:planks 30 1 {display:{Lore:[&quot;Wooden planks&quot;]}} give @s stone_pickaxe{Unbreakable:1b} give @s item_frame{EntityTag:{Invisible:1b}} summon villager ~ ~ ~ {Offers:{Recipes:[{buy:{id:&quot;emerald&quot;,Count:5b},sell:{id:&quot;diamond_sword&quot;}}]}} summon tnt ~ ~ ~ {Fuse:20s}
Here is an interesting piece of code that my fellow team members were just having a slightly heated discussion about...    Dim fred As Integer    If True Then fred = 5 : fred = 3 : fred = 6 Else fred = 4 : fred = 2 : fred = 1   After executing the above code snippet, what is the value of fred?  Try not to cheat and debug the code.  This is a highly contrived code example that started out as an example of using the colon with an If statement, but then someone decided to take it upon themselves to proffer a result for fred.  UPDATE: I would not normally write code like this and this snippet only serves as an example. As it so happens, this question originated from a discussion involving the creation of a coding standards document for our team. Prove that $\gcd(a^n - 1, a^m - 1) = a^{\gcd(n, m)} - 1$ For all $a, m, n \in \mathbb{Z}^+$,   $$\gcd(a^n - 1, a^m - 1) = a^{\gcd(n, m)} - 1$$ To prevent overfitting people people add a regularization term (proportional to the squared sum of the parameters of the model) with a regularization parameter $\lambda$ to the cost function of linear regression. Is this parameter $\lambda$ the same as a lagrange multiplier? So is regularization the same as the method of lagrange multiplier? Or how are these methods connected? VirtualBox error kernel headers I'm with Ubuntu 15.04 and I'm trying to create an emulator (genymotion), but when run virtualbox, i got the error:     Stopping VirtualBox kernel modules ...done.   Uninstalling old VirtualBox DKMS kernel modules ...done.   Trying to register the VirtualBox kernel modules using DKMSError! Your kernel headers for kernel 3.16.0-30-generic cannot be found.   Please install the linux-headers-3.16.0-30-generic package,   or use the --kernelsourcedir option to tell DKMS where it's located    ...failed!     (Failed, trying without DKMS)   Recompiling VirtualBox kernel modules ...failed!     (Look at /var/log/vbox-install.log to find out what went wrong)   I performed   uname -a   And the result is:     Linux douglas 3.16.0-30-generic #40-Ubuntu SMP Mon Jan 12 22:06:37 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux   Someone help me?Already I uninstalled and installed again. $\mathbb{Q}(\sqrt{p},\sqrt[3]{q})=\mathbb{Q}(\sqrt{p}\sqrt[3]{q})$ for distinct prime $p,q$ Can I use the "Scan" button with SANE? I have an HP Deskjet with integrated scanner. It has a "Scan" button on its top, but this button does not interact with the xsane program on my Debian machine: To get a page scanned, I have to initiate the scanning process from xsane.  Is there a setting (or a scan program) that allows me to press the scan button and cause the program to scan a page? Upgrade from MaaS 2.6.2 to MaaS 2.7 Should +1 and thanks comments be a declined flag? As a moderator for GD.SE I was always led to believe our role is to clean old comments as they are intended to be a temporary item depending on the level of context and if they add any benefit to an answer.  On SO I haven't had any issues or declines when I read old Q&amp;As and see +1 and thanks and flag.    However, on other sites when I read an old Q&amp;A and I see thanks or +1 I try to be courteous and flag them as I am aware moderators do get measured by their cleanup and I'm accustomed in doing so on SO but these flags are declined.    So this leads me to ask:   Should +1 and thanks comments be flagged and is the intended role of a comment still to be considered as temporary? What is the proper classification for a thanks or +1 comment if it should be flagged?   I didn't see any Q&amp;As on this topic after browsing the tags:   and searching led me to:  but that was several years old. Small Caps and Bold Face I can't seem to have both the small caps and boldface styles on a line:  \huge\sc\bf Hello   This will generate bold text, and if the \sc is placed after, it will generate small caps text but not bolded. They seem to override each other, so is there any way to apply them both? I am using Sql Server 2008 on Small Business Server 2003; client is using WinXP.   I added a user to my Active Directory Security Group; Why can't this user immediately access the database? It seems there is a delay before the user is recognized in Sql Server.   I am using AD Security Groups for permissions expressly so that I don't need to add individual users in Sql Server. So effectively I don't need to do anything but add the user to the AD Security Group in order to grant access.  But for some reason Sql Server doesn't immediately recognize the addition. I've seen this a number of times. I add the user to the group but that user can't access data until the next day. It seems that it doesn't query the Active Directory in real time. Can you confirm that is so?  What do I need to do so that Sql Server "refreshes" the list of users from Active Directory? Show that a matrix is nilpotent. Let $A,B \in \mathbb{M}_n (\mathbb{C})$. If $A^2B + BA^2 = 2ABA$ then exist $k \in \mathbb{N}$ where $(AB-BA)^k = 0$.  I tried solve with minimal polynomial, but I did not have much effect. Let $(B_t)_{t\geq 0}$ be a standard Brownian motion in $\mathbb{R}^d$. It is intuitive that, for fixed $s&lt;t&lt;u$  $$\mathbb{E}[B_t\mid \sigma(B_s,B_u)]=B_s+\frac{t-s}{u-s}(B_u-B_s).$$  However, I cannot think of a way to show this rigorously.   If first attempted to take $A\in\sigma(B_s,B_u)$ and show that $\mathbb{E}[1_A B_t]=\mathbb{E}[1_A(B_s+\frac{t-s}{u-s}(B_u-B_s))]$. But I cannot manage to show this equality.   I'd be very thankful for any ideas and suggestions on how to tackle this problem. How do I recreate this color overlay layer effect in Photoshop? I would like to use the overlay effect used on the screenshot(s) below.    I've tried experimenting with several Blending modes but keep missing the mark. I'm sure this has a very easy answer but I'm having trouble recreating the effect on my own.  Here are a few more images for further context:        Thanks in advance for your help. Probability of a player winning before another Given a 7 sided dice, 2 players roll it independantly simultaneously and when a player rolls a '6' he gets a prize.  What is the probability of the first player getting a prize before the second?  So my solution is to sum over all the turns j in which player 1 could win, and make the second player lose all these turns:  $$P(A) = \sum_{i=1}^{\infty}(6/7)^{j-1}*(1/7)*(6/7)^j = 0.461$$ My question is if my solution is correct, and if so, why is the probability so low? It seems to me that either player 1 wins before the 2nd or the other way around, and the probability of them playing forever is 0, so it should be 0.5? I'v found this proposition.  If $G$ is a finite  group , $ A \subset G $ a subset and $|A| &gt; \frac{|G|}{2} $ then $AA = G $.  Why this is true ? SSH welcome message on 17.04 shows notice about 12.04 I just did a do-release-upgrade going from Ubuntu 16.04 to 17.04. However, now when I login via SSH I have the following message   Welcome to Ubuntu 17.04 (GNU/Linux 4.10.0-20-generic x86_64)   * Documentation:  https://help.ubuntu.com  * Management:     https://landscape.canonical.com  * Support:        https://ubuntu.com/advantage  Ubuntu 12.04 LTS end-of-life was April 28, 2017 -- Upgrade your Precise systems!  $ sudo do-release-upgrade -m server  0 packages can be updated. 0 updates are security updates.   My question is, how can I remove the   Ubuntu 12.04 LTS end-of-life was April 28, 2017 -- Upgrade your Precise systems!  $ sudo do-release-upgrade -m server   it wasn't there prior the release-upgrade  I checked and I am on Zesty  lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description:    Ubuntu 17.04 Release:    17.04 Codename:   zesty   My question is not, how can I remove this message, this I found. My question is more, is there a reason why this appears after a release-upgrade? Is this message something generic not taking into consideration the current version of Ubuntu? Or maybe my system is not updated properly? Is there a way to combine custom settings with custom labels ? So that the output from a setting value would be a custom label ?   To explain:  In example, we have an international organisation, and say countries are stored as an ISO code. As this is a limited and stable set of data, using custom settings would be the appropriate way to deal with say the full country name.   The issue arises when I do not just want to store the English country name, but want to have it translatable, presenting the right translation depending on the user's locale. Now, this is the point where I'd like to integrate custom settings with custom labels.  So that say the custom setting with name 'some iso code' doesn't return the full country name, but Label.Country'some iso code', which is than automatically translated in the right version.   Sounds good right. But as custom settings are fixed to certain types, as far as I've gotten is put the label name in the settings as a string value. And then .. i'm stuck :).  No way to cast a string to a Custom label, or have it be interpreted (and translated) as such, or is there ?   I'm aware this can be done in a custom object &amp; apex, I was hoping for a more automated, "cleaner", less resource consuming way, better integrated, configurable way.  Additional clarrification: *The goal is to extend the use of custom labels (translation workbench), by adding a mapping from any data-based value to a custom label.*   While we could do a long matching process in apex, it would be faster &amp; neater if the custom settings mechanism could be used. There are disadvantaged to custom objects, they require soql &amp; apex, while custom settings &amp; custom labels are cached. They too can be used in many other places. Countries were an example, I'd use this mechanism for every variable value that needs to be translatable. How can I tell which cards or sets are currently legal in various formats? I haven't played Magic: the Gathering since the days of Onslaught and Mirrodin, and I would like to try to catch back up. Since all my cards are quite dated now, I may be more interested in formats other than the most up-to-date one.  Rather than ask what is currently legal in various formats (since that is likely too localized), I would rather pose the question of how can I tell which sets/cards are legal in each format. How to integrate $\int x^2 \sin^2(x)dx$ I don't know how to integrate $\int x^2\sin^2(x)\,\mathrm dx$. I know that I should do it by parts, where I have  $$ u=x^2\quad  v'=\sin^2x \\  u'=2x \quad v={-\sin x\cos x+x\over 2}$$  and now I have  $$ \int x^2\sin^2(x)\,\mathrm dx = {-\sin x\cos x+x\over 2} x^2 - \int 2x{-\sin x\cos x+x\over 2}\,\mathrm dx\\ ={-\sin x\cos x+x\over 2} x^2 - \int x(-\sin x\cos x+x)\,\mathrm dx\\  $$  so I have to calculate $$ \int x(-\sin x\cos x+x)\,\mathrm dx=-\int x\sin x\cos x\,\mathrm dx+\int x^2\,\mathrm dx$$  I know that $\int x^2\,\mathrm dx = {1 \over 3}x^3+C$ but I don't know what should I do with $$\int x\sin x\cos x \,\mathrm dx$$ Should i use parts again or what? Please help. What does size of a directory mean in output of 'ls -l' command? What does size of a directory mean in output of ls -l command?