A curve fitting program will not calculate the values of the parameters, in this case A and B of the function y = A + (B*x), but it will try many values for A and B to find the optimal value. The best value for A and B is found with the least squares method when the sum of squares is minimal. A curve fitting program will iterate and use many values for A and B, but it needs values for A and B to start. These are called the start values. If the values for A and B are far away from the optimal value, sometimes the fitting program cannot find the appropriate values as it is impossible to test all possible values. Usually the fitting algorithm only modifies the parameters A and B slightly and then calculates if the modification is better or worse compared to the already calculated values. A great example how a an interation over parameters can influence the residuals can be found on desmos.