The following is the solution of the question in the last post. Printing the prime numbers between 1 and 100. This may not be the best logic, yet it gets what to be done. It is more important to develop a timely solution than an untimely one.
wscript.echo "1" |
and the output
C:\scripts>cscript prime.vbs //nologo |
Some more examples that you should try
1. List the Fibonacci series – first 15 numbers
2. Find the Square root of any number correct to 4 decimal places. (use Newton’s method)
No comments:
Post a Comment