Mechanically, work done is equal to (symbols have their usual meanings).
Work is the cumulative action of force upon an object over a path and only the component of force that is perpendicular to motion has any effect.
There is a category of forces, however, called conservative forces”\, for which this number comes out the same for all paths connecting any given pair of positions. Gravity, electric field force, and many others presented to early physics students, are examples from this category.
In cases where only a single force acts, and that force is conservative, and furthermore that force is approximately constant over the domain of space under consideration, the above formula simplifies to:- W = F.S
Since work done is the dot product of two vectors so w =F.S so S must be displacement not distance which is a scalar quantity