You may have been thinking about the function , for which the domain and range are all real numbers. However, the domain is restricted because you must have . So the domain is . Because the square root must always be positive or 0, the range is .