|
|
|
|
|
|
Sunday, October 23, 2022
Notes on C++ with OOP eBook related articles list
Friday, June 17, 2022
Why To Become an Arduino Developer
Said in one line: Learn hardware-software-coding with one board.
Before
knowing how to become…? One will definitely ask why I should learn Arduino?
For that
question, answer is in our environment…
This is a
digital age, we are living in the digital world. Everything around you are
digital in nature. You can control it, operate it and living with it without
knowing what is inside it and how it is made.
But lack of
digital awareness makes you less confident and lag with life.
…so you
need “digital Awareness” for confident living!
Whether you are a kid, student,
housewife, businessman, politician, hobbyist or engineer you must have sound
digital awareness for confident living in this 21st century world.
…so what
exactly it means by this “digital Awareness”?
Learn to build any such digital
device by own, control it with the proper interface, program it to do as you
desire and during this process knowing digital-device’s inside-out.
…to acquire
“digital awareness” one needs hardware-software-coding platform
An Arduino provides one such
platform where all the three processes-hardware=software=coding can be carried
out without much effort and money.
…so become
an Arduino developer now!
Decide now only that, I will become
an Arduino developer within a week and enhance my digital awareness
efficiently.
Even you can add the skill to your
bio-data for a showcase purpose.
Even you can develop real-time,
working digital systems with an Arduino developer skill for your home or an
office or the business.
…so learn
Arduino today and become an updated embedded engineer!
Good news is the Arduino is an
open-source platform. The Plenty of information is available on internet
freely. Google it!
For why to become an Arduino
Developer and how to become an Arduino Developer explained in steps, in this below
video. |
Free eBook
in Google play store for download: |
…till next post,
bye-bye and take care.
Sunday, May 8, 2022
Simple Write a program assignment in C language-04
Learning C programming language is mandatory for today’s students [as one programming language], during their academic career. The C language has many mechanisms to deal with decision making, repetitive tasks, such as if, if…else, for, while etc. Here are some of such C codes which may asked in theory/practical exams.
C is
a typed language, so no need of code explanation as everything will be cleared
by itself by reading the code. If you know C, you know this code. It’s that
simple!
The
Code::Blocks IDE 20.03+MinGW and Cygwin tool are used to test the code.
Code7 |
Write A Program to display counting from
10 to 1 using for loop |
|
|
//WAP#7:WAP to display
counting from //10 to 1 using for loop /* #include <stdio.h> #include <stdlib.h> int main() { for(int i=10; i >=1; i--) printf("%d\n",i); return 0; } //end of program //----------------------- //output WAP#7: /* 10 9 8 7 6 5 4 3 2 1 */ |
|
|
|
|
Code8 |
Write A Program to display even numbers
between 1 and 20 using for loop |
|
|
//WAP#8:WAP to display
even numbers //between 1 & 20
using for loop /* #include <stdio.h> #include <stdlib.h> int main() { for(int i=2; i <=20; i+=2) printf("%d\n",i); return 0; } //end of program //-------------------------- //output WAP#8: /* 2 4 6 8 10 12 14 16 18 20 */ |
|
|
|
|
Code9 |
Write A Program to display a table for
equivalent temperature in Fahrenheit to Celsius from 50F to 100F with an
increment of 5 |
|
|
//WAP#9:WAP to display a
table of //equivalent temperature
in Fahrenheit //to Celsius from 50F to
100F with an //increment of 5 /* #include <stdio.h> #include <stdlib.h> int main() { int fah; float Cel; //declare variables printf("Faharenheit\t
Celisus\n"); for( fah=50; fah <=100; fah=fah+5) { Cel=5.0/9.0*(fah-32);
printf("%3d\t\t%6.2f\n",fah,Cel); } return 0; } //end of program //----------------------- //output WAP#9: /* Faharenheit Celisus 50 10.00 55 12.78 60 15.56 65 18.33 70 21.11 75 23.89 80 26.67 85 29.44 90 32.22 95 35.00 100 37.78 */ |
|
|
|
|
Code10 |
Write A Program to display user-defined
series using while loop |
|
|
//WAP#10:WAP to display
user-defined //series using while loop /* #include <stdio.h> #include <stdlib.h> int main() { int i, j;//declare variables i = 0; j = 1; while(i <=6) { printf("%d\t%d\n",i,j); i=i+1; j=j*2; } return 0; } //end of program //---------------------------- //output WAP#10: /* 0 1 1 2 2 4 3 8 4 16 5 32 6 64 */ |
|
|
|
|
Code11 |
Write A Program to display triangle shape
using nested for loop |
|
|
//WAP#11:WAP to display
triangle //shape using nested for
loop /* #include <stdio.h> #include <stdlib.h> int main() { for(int i=1; i<=5; i++) { for(int j=1; j<=i; j++) { printf("*"); } printf("\n"); } return 0; } //end of program //------------------------- //output WAP#11: /* * ** *** **** ***** */ |
|
|
|
|
For such codes click CCode label or check next day post on
right-side post history bar.
---till next post, take care and bye-bye.
Saturday, May 7, 2022
Simple Write a program assignment in C language-03
Learning
C programming language is mandatory for today’s students [as one programming
language], during their academic career. The C language has many mechanisms to
deal with decision making, repetitive tasks, such as if, if…else, for, while
etc. Here are some of such C codes which may asked in theory/practical exams.
C is
a typed language, so no need of code explanation as everything will be cleared
by itself by reading the code. If you know C, you know this code. It’s that
simple!
The
Code::Blocks IDE 20.03+MinGW and Cygwin tool are used to test the code.
Code4a |
Write A Program to ask user for base
value and then display a factorial number using while loop
|
|
|
//WAP#4a:WAP to ask user
for base value & // then display a
factorial number using // while loop /* #include <stdio.h> #include <stdlib.h>
int main() { int num,counter, fact;//declare variables counter = 1; fact = 1;
printf("Enter base value [integer]:
"); scanf("%d",&num); //get
base value
while (counter <= num) { fact = fact * counter; counter = counter + 1; printf("%d\t",fact); } printf("\n Factorial of %d is =
%d\n",num,fact); return 0; } //end of program
//------------------------- //output WAP#4a:
/* Enter base value
[integer]: 6 1 2
6 24 120
720 Factorial of 6 is = 720 */ |
|
|
|
|
Code4b |
Write A Program to ask user for base
value and then display a factorial number using do…while loop
|
|
|
//WAP#4b:WAP to ask user
for base value & // then display a
factorial number using // do...while loop /* #include <stdio.h> #include <stdlib.h>
int main() { int num,counter, fact;//declare variables counter = 1; fact = 1;
printf("Enter base value [integer]:
"); scanf("%d",&num); //get
base value
do { fact = fact * counter; counter = counter + 1; printf("%d\t",fact); } while (counter <= num); printf("\n Factorial of %d is =
%d\n",num,fact); return 0; } //end of program //------------------------- //output WAP#4b:
/* Enter base value
[integer]: 6 1 2
6 24 120
720 Factorial of 6 is = 720 */ |
|
|
|
|
Code4c |
Write A Program to ask user for base
value and then display a factorial number using for loop
|
|
|
//WAP#4c:WAP to ask user
for base value & // then display a
factorial number using // for loop /* #include <stdio.h> #include <stdlib.h>
int main() { int num, fact;//declare variables fact = 1;
printf("Enter base value [integer]:
"); scanf("%d",&num); //get
base value
for(int i=1; i<=num; i++) { fact = fact * i; printf("%d\t",fact); } printf("\n Factorial of %d is =
%d\n",num,fact); return 0; } //end of program
//------------------------- //output WAP#4c:
/* Enter base value
[integer]: 6 1 2
6 24 120
720 Factorial of 6 is = 720 */ |
|
|
|
|
Code5 |
Write A Program to display first five
numbers with their cubes using do…while loop
|
|
|
//WAP#5:WAP to display
first 5 numbers //with their cubes using
do...while loop /* #include <stdio.h> #include <stdlib.h>
int main() { int i;//declare index i = 1;
do { printf("%d\t %d \n",i,
i*i*i); i = i + 1; }while (i <= 5);
return 0; } //end of program
//--------------------------- //output WAP#5:
/* 1 1 2 8 3 27 4 64 5 125 */ |
|
|
|
|
Code6 |
Write A Program to display first 10 odd
numbers using do…while loop
|
|
|
//WAP#6:WAP to display
first 10 odd numbers //using do...while loop /* #include <stdio.h> #include <stdlib.h>
int main() { int i;//declare index i = 1;
do { if((i%2) != 0) printf("%d\n",i); i = i + 1; } while (i <= 20);
return 0; } //end of program */ //output WAP#6:
/* 1 3 5 7 9 11 13 15 17 19 */ |
|
|
|
|
For such codes click CCode label or check next day post on
right-side post history bar.
---till next post, take care and bye-bye.