Tuesday 11 July 2017
CSS Animation
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Monday 10 July 2017
Putchar
Putchar 'C 'Output Function
Putchar write
a character to standard output (monitor). It takes argument as character and returns
its integer form without sign. If a writing error occurs, EOF is returned and
the error indicator (ferror) is set.
#include<stdio.h>
void main()
{
char ar[]={"Girfa"};
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Sunday 9 July 2017
Getchar
Getchar Function
Getchar takes
input a character from standard input (stdin) and return integer value without
sign.
int main(void)
{
int c;
/* Note that
getchar reads from stdin and
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Saturday 8 July 2017
getche
Getche function
Getche is same
as getch function, both takes input from keyboard the difference is return
type.
- Getch does not echo given character only return integer value
- Getche echo and return integer code of given character
#include<stdio.h>
void main()
{
char n;
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Getch
Getch takes
input a character from keyboard. Getch
is different from scanf because user need to press enter explicitly to complete
input process but getch intensely return pressed key ASCII.
Some people
used getch to hold program output
because when getch excuted it wait for a character and until user press a
character next statement would not get executed.
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Friday 7 July 2017
Switch Case C Language
Switch Case
A switch case is uncomplicated solution/alternate of
complicated nested if-else. It is useful when there is a need check to arise
multiple possibility on single variable like print day of the week name based
on the given day number. Best for long if statements that compare a variable to
several "integral" values ("integral" values are simply
values that can be expressed as an integer, such as the value of a char).
Above figure is showing syntax of switch case. In syntax
break and default are in bracket, which means they are optional. You can use
more than one case without using break. If break is omitted, then all the ca
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Thursday 6 July 2017
Java Script Date dd/mm/yyyy format
Get Java Script Date dd/mm/yyyy format
<html>
<head>
<title>Girfa
Student Help</title>
<script>
function
GetDate()
{
var d = new Date();
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Lucas Series
Lucas Numbers similar to the Fibonacci series that often occurs when working with the Fibonacci series. Edouard Lucas (1842-1891) (who gave the name "Fibonacci Numbers" to the series written about by Leonardo of Pisa) studied this second series of numbers: 2, 1, 3, 4, 7, 11, 18, .. called the Lucas numbers in his honour. On this page we examine some of the interesting properties of the Lucas numbers themselves as well as looking at its close relationship with the Fibonacci numbers. The following page generalises further by taking any two starting values.
/* ####### Girfa Student Help
###############
Lucas Sequesnce Program
for more program visit :
https://girfahelp.blogspot.in/p/c-language-assignment.html
############################################## */
#include<stdio.h>
void main()
{
int a,b,c;
clrscr();
a=1;
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Saturday 24 June 2017
Number to word convert
Q : Write a program to convert a number into its equivalent word without using character array?
/*
##########################################
Girfa : Student Help
Program : Number to word converter
for more program visit :
##########################################*/
#include<stdio.h>
#include<conio.h>
void single(int);
int reverce(int);
void ten(int);
void hundred(int);
void
printhundred(int);
void main()
{
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Thursday 22 June 2017
Looping With Cursor SQL Server
Cursor is an database object which is use when there is a
need to process table record row by row . you can access each field of your
table at record by record. In relational databases, operations are made on a set of
rows. For example, a SELECT statement returns a set of rows which is called a
result set. Sometimes the application logic needs to work with a row at a time
rather than the entire result set at once. In T-SQL, one way of doing this is
using a CURSOR. For example when we want to get record from one table and need
to insert into another with performing some logic or some conditions .For
example if we want to get value from one table row by row and need to perform some logic over that and
update /insert into another table then we can use cursors. Cursor basically
works as for/While loop.
USE [Girfa_tportal]
GO
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
alter procedure [dbo].[GetStudentContact]
as
begin
Declare @phone as varchar(15)
Declare @email as varchar(50)
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Wednesday 21 June 2017
Multiple Return SQL Server Function
Table value function
For return more than value from SQL-Server? To do so you
need to make table value function.
A table value function use to return more than one value in
the form of table.
USE [Girfa_portal]
GO
/****** Girfa Student Help ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
create FUNCTION [dbo].[getBookIssueFineDay]
(
@roll int
)
RETURNS TABLE
as
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Tuesday 20 June 2017
SQL Server Function
Function declaration
USE [Girfa_Portal]
GO
/******
Girfa Student Help******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
ALTER FUNCTION [dbo].[getBookStock] (@bookcod varchar(50))
RETURNS int
AS
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Saturday 17 June 2017
PHP Hotel Management Project
PHP Hotel Management Project
This project target Hotel Website
or computer science student for their project work. Anyone who wants to make a
website on Hotel Management or Any student want to submit their project on the
topic of Hotel Management then this project is best solution. I have made it simple,
Responsive for all device and professional look. Intention of this project is
only for learning for earning money so any use of this project for earning money
is prohibited.
Video Shop
Live Preview
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Thursday 15 June 2017
Delete Data Grid View Row
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Tuesday 13 June 2017
Zombie Process
In UNIX or its similar OS environment if a process stops
running abnormally but its entry has not removed from process table known as
Zombie Process.
Reason
If a process gets stop with exit and meanwhile parent
process is sleeping then parent will be able to known the status at sleeping
moment and entry of the killed process still in process table which imply Zombie.
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Friday 9 June 2017
C Language NIELIT Exam Paper Solution
NIELIT O Level
C Language Paper Answer
January - 2015
1: Objective
1.1 B
1.2 : C
1.3 : D
Explanation : Because pointer is not being part of any equation so option a and d is equal.
1.4 : D
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Write a C program to modify the constant variable.
Q : Write a C program to modify the constant variable.
Solution :
#include<stdio.h>
void main()
{
const int a=1;
int *p;
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Thursday 8 June 2017
What is automatic type promotion in c
Q : In the following declaration statement:
char c=’A’;
Variable c stores one byte of memory space while character constants ‘A’ stores one byte memory space. How one byte variables can stores two byte character constant? What is automatic type promotion in c?
Solution :
Character constant reserve two byte of memory space to represent
octal or hexadecimal character constant but char variable stores only its one
byte ASCII value.
In C language, char type is used to store a 1 byte integer.
When you assign 'A' to char c, you are not assigning the letter A itself into
memory. Rather, you are assigning the number (integer) representing the A
character. Each letter has a digit that represent it. . Remember that unlike
humans, computers cannot understand letters. That's why we need a way to
translate them into digits. To do this we use differnet coding styles like:
ASCII, UTF-8, etc If your machine use ASCII coding then the value assigned to
char c would be 65 (0x41 hex). As you may notice, 0x41 is one byte and can be
stored in your char variable.
Automatic type promotion
Some data types like char , short int take less number of
bytes than int, these data types
are automatically promoted to int or unsigned int when
an operation is performed on them. This is called integer promotion. For
example no arithmetic calculation happens on smaller types like char, short and enum. They are first
converted to int or unsigned int, and then
arithmetic is done on them. If an int can represent all
values of the original type, the value is converted to an int . Otherwise, it is
converted to an unsigned
int.
int main()
{
char a = 30, b = 40, c = 10;
char d = (a * b) / c;
printf ("%d ", d);
return 0;
}
At first look, the expression (a*b)/c seems to cause
arithmetic overflow because signed characters can have values only from -128 to
127 (in most of the C compilers), and the value of subexpression ‘(a*b)’ is
1200 which is greater than 128. But integer promotion happens here in
arithmetic done on char types and we get the appropriate result without any
overflow.
Consider the following program as another example.
Next Question
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Text File Input Through C Language
Q : Write a C program to write a line of string in a text file.
Solution :
#include<stdio.h>
void main()
{
FILE *pt;
char
ch[100],c;
int i;
pt=fopen("test.txt","w");
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Monday 5 June 2017
Gridview FIll VB.net
Dynamic fill data gridview using VB.net
Public Sub
fill_gridview(ByRef dt As
DataGridView, ByVal sql As String)
Dim con
As New
OleDbConnection(getconstr)
Dim da As New
OleDbDataAdapter(sql, con)
Dim ds As New DataSet
Try
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Saturday 3 June 2017
Division Flipper Using CSS
Division Flipper Using CSS
Girfa
Student Help
Full Code :
<html>
<head>
<title>Girfa : Flip Effect </title>
<style>
.flip-container {
perspective: 500px;
}
/* flip the pane when
hovered */
.flip-container:hover .flipper, .flip-container.hover .flipper {
transform: rotateY(180deg);
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Friday 2 June 2017
Write a C program that displays the recommended actions depending on the color of a traffic light using the switch statement.
Q : Write a C program that displays the recommended actions depending on the color of a traffic light using the switch statement.
Solution :
void main (void)
{
char colour;
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Thursday 1 June 2017
Define void data type and write any three use of it.
Q : Define void data type and write any three use of it.
The data type void actually refers to an object that does not have a value of
any type. Void is also used to indicate when a function does not return a value
or no argument. Such a function is used for its side effect and not for its
value. In the function declaration and definition, we have indicated that the
function does not return a value by using the data type void to show an empty type, i.e. no value. Similarly, when a
function has no formal parameters, the keyword void is used in the function prototype and header to signify that
there is no information passed to the function.
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
What is dangling pointer in C? What is wild pointer in C? Give example.
Q : What is dangling pointer in C? What is wild pointer in C? Give example?
Dangling Pointer
Dangling or wild is a pointer which does not point
valid object. When a pointer has declared it must be assign a valid
address memory address otherwise it will point some location which is not
valid. These are special cases of memory safety violations.
More generally, dangling references and wild references are references that do not resolve to a valid destination.
Void main()
{
int *pt;
{
int
c=10;
pt=&c;
}
printf("\n\t%d",*pt);
}
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Sunday 28 May 2017
Setting Combo-box Value and Display Data with VB.Net
I was working on a Brokerage Calculation project where I
need to load a table’s data into combo box as in the form of value member and
display member because a combo-box store two value ID which not shown at drop
down list but reside in combo-box .
We need to Set/Get data through value because it’s mostly
primary key and display mode for display
field. Take a look on following code:
Dim con As New
OleDbConnection(getconstr)
Dim da As New
OleDbDataAdapter(sql, con)
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Friday 26 May 2017
What are merits and demerits of array in C?
Q : What are merits and demerits of array in C?
Why
we need an array.
We
need array when there is a need to process more than data with similar type. For
example
- Taking marks of 10 student needs of ten integer
- Taking name of more than one character
- Structure record and many more
Criteria
mentioned above can also be achieved through variable , but variables have
following drawback which lead to use array instead of Variable.
- Each variable must has unique name which increase complexity when a large number of variables need to make.
- Each variable load in memory at random order. So if you want to process all variable then you need to process each variable individually because allocation of space is not continuous.
For
understand the above point you need to imagine a real life example.
Two
close friend group decided to watch a movie and they follow two different approaches
as follows
- Friends in Group one purchase ticket individually without any coordination between them for seating arrangement
- Friend in group two book seats continuously i.e. seats no 1 to 10.
So
Group two can make better communication than group one. In same way array
works.
Advantage
- Continuous memory allocation.
- Process a collection of similar data type.
- Can be used to make data structure like stack,tree,queue etc.
- Easy to visit each element using index.
Disadvantage
- Static memory allocation
- Due to static memory allocation number of element cannot be increase nor decrease at run time.
- The elements of array are stored in consecutive memory locations. So insertions and deletions are very difficult and time consuming.
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Write a C program to find size of structure without using sizeof operator.
Q : Write a C program to find size of structure without using sizeof operator.
#include<stdio.h>
#include<conio.h>
struct stu
{
int roll;
char
name[20];
float
marks[3];
};
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Write a C program to find the square root of a given quadratic equation.
Q1 : Write a C program to find the square
root of a given quadratic equation.
#include <math.h>
int main()
{
double a, b, c, determinant, root1,root2, realPart,
imaginaryPart;
printf("Enter
coefficients a, b and c: ");
scanf("%lf
%lf %lf",&a, &b, &c);
determinant =
b*b-4*a*c;
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Wednesday 24 May 2017
Write a C program to print given number of terms of a Fibonacci series.
Q 1 : Write a C program to print given number of terms of a Fibonacci series.
Solution :
#include<stdio.h>
void main()
{
int a,b,c;
c=1;
a=0;
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Write a C program to read a line and print it reverse using recursive function.
Q : Write a C program to read a line and print it reverse using recursive function.
Solution :
#include<stdio.h>
#include<string.h>
#include<process.h>
void print(int len,char str[])
{
int n=len;
if(n==-1)
exit(1);
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Sunday 7 May 2017
Call by value Call by reference
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Wednesday 3 May 2017
Customized web page print using Java Script
Printing a webpage is another
important aspect of web development. If you skip this section then when your
user will be print a page then it will print as it is, which not good for all
case because we add a lot of formatting images on webpage. So all the things on
the page will get printed that will be worse.
Customizing web page output is good practice to make a
webpage. Because what we see on web page we don’t need to take output on paper
same format so customization is mandatory.
Roll | Name | City |
---|---|---|
101 | Sona | Vns |
102 | Amit | Alld |
103 | Sumi | Alld |
104 | Rakesh | Vns |
105 | Jyoti | alld |
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Saturday 29 April 2017
Stock and Bill Management Project
I have made this project for your practice only this is live
project running in whole sale shoes shop. You can use this project as your
course final project because I have seen many students who buy project from
market or internet so I made this project online for download every one with
free of cost. I also suggest student who’re going to make this project as their
course project, please take a look on project and understand what the flow of
this project working model are. I don’t want to make use this project as
shortcut to only submitting your project. No! This is wrong so try to learn
some live coding from this project.
Commercial use of this project without consent is
prohibited.
Project Description
This helps to manage stock and
billing of a whole shale shop. Primary this project was design for a shoes shop
but it can be apply the business which sells some company project which has
further some sub type. All the entry left blank. So you can create your own entry.
Some demo records are in download database for sake for understood of project
work flow. One you will be understands work flow then you customize this
project as your requirement.
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Friday 28 April 2017
Inheritance OOP
Inheritance (Object Oriented Programming)
In object-oriented programming,Inheritance allows us to define a class which is based on another class, which makes it easier to create and maintain an application. This also provides an opportunity to reuse the code functionality and fast implementation time.The derived class is also called subclass and the base class is also known as super-class. The derived class can add its own additional variables and methods. These additional variable and methods differentiates the derived class from the base class.inheritance saves our money and time both because we use predefined compile and tested class which increase quality of software.
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Tuesday 25 April 2017
Function Pointer
Function pointer is a type of pointer which points a function or code block. You can assign address of a function to function pointer variable and that function using function pointer variable name.
I have a bad experience while making Calculator. In my design all the calculation takes place when user pressed equal button. When a user pressed equal button I need to check every time which operator user was pressed , checked by switch case, it become complicated then I increase more function in my calculator because of lots condition for operator check and attached code for particular logic separately.
Now my work becomes simple because of function pointer because I just need to check operator pressed by user and attached related function code to function pointer. It reduces lots of condition checking and assigns separate code to each section. So function pointer is very useful in some specific scenario.
Advantage of function pointer
- Implement Callback
- Useful in event handling
- One entry point for more than one code block
A programmer and Founder of Girfa
IT Services, working from 2009.At Starting computer teaching was my full-time job but after 10 years of teaching I chose to programming as a full-time job and teaching become part-time. In real life, I am very lazy and I made it my coding style I always try to make a reusable component that’s my USP for programming which saves my time and extra working both.
Subscribe to:
Posts (Atom)