Field Manual for Hackers

https://www.hackonly.com

Ethical Hacking Training Online | LearnSkill.Today

Ethical Hacking Training Online | LearnSkill.Today

Search

Labels

Labs Java PHP Python Network Security Quiz Android AWS C++ Web Application Security Exploit Writing Linux C Language Kali Linux Commands django Shell Script :Labs Cheatsheet How to Install MySql OWASP Penetration Testing Post Exploitation fix Android Pentesting Capture the Flag Case Study Hack the box SEO Sniffing TCPDUMP Tools Wireshark

python | for loop lab

For loop

1. Write a program which accept a number ‘N’ and then find the sum of the integer from 1 to 2, then 1 to 3 then 1 to 4 and so forth until it display the sum of integers from 1 to N.

2. Write a program to print a factorial table using for loop
For ex         1!     1
      2!                2
      3!               6

3. Write a program to test whether a given number is prime or not.?(Use GOTO statement).

4. Above program without goto statement.

5. Print all the prime numbers between two given numbers.

6. Write a program to compute the sum of first ‘N’ terms (n>=1) of the series
          1-3+5-7+9……………………


For loop Nesting

7.Write a program to print the multiplication table
1 2 3 4 5 6 7 8 9 10
2 4 6 8 10 12 14 16 18 20
.
.
Email ThisBlogThis!Share to TwitterShare to Facebook
Reactions:

  No Comments

Newer Post Older Post Home

0 comments:

Post a Comment

Ethical Hacking Training Online | LearnSkill.Today

Ethical Hacking Training Online | LearnSkill.Today

Translate

Follow by Email

Copyright © Field Manual for Hackers | Designed by V2Geeks

TOP