In many examples we take square waves as digital signals. But a digital signal should be discontinuous in time and must have a finite amplitude level. Another explanation that negates a square wave being digital is " According to fourier analysis a square wave can be represented as the sum of harmonics of infinite number of sinusoidal signal". Hence we can say that a square wave is not digital in nature. As it has only two level of amplitude it would be wrong if one says that it is analog because an analog signal must have an infinite number of amplitudes, i.e. be continuous in amplitude.