You may also use reminder theorem, such that:

`p(x) = (x - 1)^2*q(x) + r(x)`

The problem provides the information that the polynomial `p(x)` is exactly divided by `(x - 1)^2` , hence, `r(x) = 0.`

Since the degree of polynomial `p(x)` is 4, hence, the degree of `q(x)` needs to be 2, such that:

`ax^4 + bx^3 + 1 = (x - 1)^2*(cx^2 +dx + e)`

`ax^4 + bx^3 + 1 = (x^2 - 2x + 1)*(cx^2 +dx + e)`

`ax^4 + bx^3 + 1 = cx^4 + dx^3 + ex - 2cx^3 - 2dx^2 - 2ex + cx^2 +dx + e`

Equating the coefficients of like powers yields:

`{(a = c),(d - 2c = b),(-2d + c = 0),(-3e + d = 0),(e = 1):}`

`e = 1 => d = 3 => c = 6 => a = 6 => b = 12 - 3 = 9`

**Hence, evaluating a and b, under the given conditions, yields `a = 6` and **`b = 9.`

We notice that x = 1 is a multiple root. Since the order of multiplicity is 2, it means that x = 1 is the root of the polynomial and the root of the first derivative of the polynomial.

p(1) = 0

p'(1) = 0

We'll calculate p(1), substituting x by 1 in the expression of polynomial:

p(1) = a + b + 1

a + b + 1 = 0

a + b = -1 (1)

Before calculating p'(1), we'll have to determine the expression of the first derivative:

p'(x) = 4ax^3 + 3bx^2

We'll substitute x by 1:

p'(1) = 4a + 3b

4a + 3b = 0 (2)

We'll multipy (1) by -3:

-3a - 3b = 3 (3)

We'll add (2) + (3):

4a + 3b - 3a - 3b = 3

We'll combine and eliminate like terms:

a = 3

3 + b = -1

b = -4

**The polynomial is: p(x) = 3x^4 - 4x^3 + 1**