In[]:=
Clear[f]​​f[x_]=2E^(2x)-a(x-1);​​​​(*Solveforausingtheequalityofthetwofunctionevaluations*)​​solution=Solve[f[x2]==f[x1],a]​​
Out[]=
a
2(
2x1

-
2x2

)
x1-x2

In[]:=
Clear[f]​​f[x_]=2E^(2x)-a(x-1);​​​​(*Reduceforausingtheequalityofthetwofunctionevaluations*)​​solution2=Reduce[f[x2]==f[x1],a]
Out[]=
x1-x2≠0&&a
2(
2x1

-
2x2

)
x1-x2
||x2x1
In[]:=
solution2[[1,2]]
Out[]=
a
2(
2x1

-
2x2

)
x1-x2