This is a starter query. I know if I enter 2+2 and press enter, I get 4.
Similarly, I enter expr = 5x + x^3 + Sin[x] and press enter. Next, I want to perform an operation with it, which is to extract the power of x , i.e., 3. This is not clear to me, how to single out this operation on Wolfram Cloud to do so. All I see is a new line after expr = 5x + x^3 + Sin[x] and enter.
What that is doing is replacing everything in expr that matches the pattern _+x^a (and that is your entire expression) with whatever the a matched, which is just your exponent, and that will give you the desired 3.
You could in this specific example do
expr[[2,2]]
and that would extract the second item in expr, which will be x^3, and then extract the second item inside that, which will be your desired 3.