How do I write this on the computer? Ignore the - they are just placeholders for spaces.
y = 1
---____ - 2
---x - 4
Are you asking how to actually typeset the expression? I suggest using LaTeX; there are many tutorials available on the Internet.
If you need to use $\displaystyle \text{\LaTeX}$ on this forum, use [tex] and [/tex] tags.
For your function,
[tex]y = \frac{1}{x-4} - 2[/tex]
gives
$\displaystyle y = \frac{1}{x-4} - 2$
Yes. And thank you for trying to make your plaintext mathematics unambiguous; many people do not use the proper notation for what they are trying to represent.
You just need to be familiar with the standard order of operations. Anything grouped by parentheses is evaluated first, exponentiation comes next, followed by multiplication and division (left-to-right), and then addition and subtraction (left-to-right).
Here are some things to watch out for:
After grouping, exponentiation always comes first. e^2-x means $\displaystyle e^2-x,$ so for $\displaystyle e^{2-x}$ you should write e^(2-x). Similarly, when writing rational exponents, make sure you use parentheses. 2^1/2 would technically mean
$\displaystyle \frac{2^1}2.$
Next, be careful with rational functions: division comes before addition or subtraction. So x^2-3x+2/x-2 means
$\displaystyle x^2-3x+\frac2x-2;$
but, for
$\displaystyle \frac{x^2-3x+2}{x-2},$ you should write (x^2-3x+2)/(x-2).
Finally, be careful when you are dealing with functions, limits, summations, integrals, or anything that can take an expression as an argument. The usual convention is for the argument/operand to include everything to the right up to the first addition or subtraction (unless it is in parentheses). sin x+2 should mean $\displaystyle (\sin x)+2;$ use sin(x+2) to indicate $\displaystyle \sin(x+2).$ But it is usually okay to express $\displaystyle \sin(2x)$ as sin 2x.
And remember that it is usually never a bad idea to use extra parentheses even where they are not needed, just to further clarify what you are trying to write (as long as you don't do something obviously obnoxious like throwing 20 parentheses around each number). If you are trying to write $\displaystyle \ln(2x)+5,$ you should be able to get away with doing ln 2x+5, but it would be much better to write ln(2x)+5 to eliminate any confusion.