Step 1: Identify the given quantities.
Mass of first block is \(40 \, kg\).
Mass of second block is \(60 \, kg\).
Applied force on the \(60 \, kg\) block is \(1000 \, N\).
The surface is frictionless, so there is no opposing frictional force.
Step 2: Find the total mass of the system.
Since both blocks are connected by a string, they move together with the same acceleration.
Total mass of the system is
\[
m = 40 + 60 = 100 \, kg
\]
Step 3: Calculate the acceleration of the system.
Using Newton's second law,
\[
F = ma
\]
\[
1000 = 100a
\]
\[
a = 10 \, m/s^2
\]
Step 4: Calculate the tension in the string.
The tension in the string is the force responsible for accelerating the \(40 \, kg\) block.
So, for the \(40 \, kg\) block,
\[
T = ma
\]
\[
T = 40 \times 10
\]
\[
T = 400 \, N
\]
Step 5: Final conclusion.
Hence, the tension in the string is
\[
\boxed{400 \, N}
\]