true

Find the best tutors and institutes for BSc Tuition

Find Best BSc Tuition

No matching category found.

No matching Locality found.

Outside India?

Search for topics

Post a Lesson

All

All

Lessons

Discussion

Answered on 16/03/2019 Tuition/BSc Tuition/BSc Computer Science

How to do correspondence T.Y B.Sc(IT) course with a new syllabus from Mumbai University, after 4 years gap?

Ruhinaz

Tutor

Clear the basic studies already done in 1st n 2nd year of bsc subject then go through the syllabus and note down the things u know then u cann make ur own notes and google will help u in that as per a tutor take help of best IT tutor for hard topics who can make you understand better than 1st read more

Clear the basic studies already done in 1st n 2nd year of bsc subject then go through the syllabus and note down the things u know then u cann make ur own notes  and google will help u in that as per a tutor take help of best IT tutor for hard topics  who can make you understand better than 1st

Dislike Bookmark

Lesson Posted on 23/12/2017 Tuition/BSc Tuition/BSc Computer Science

Ashutosh Singh

I have been teaching computer science & engineering on multiple platforms. I have a rich experience of...

#include using namespace std; int sum(int a,int b) { return a+b; } void f2(int (*f)(int,int),int a,int b) //'*f' is a POINTER TO A FUNCTION whose RETURN TYPE is //'int' and arg type (int,int) . Here, '*f' is FORMAL PARAMETER { ... read more

#include
using namespace std;

int sum(int a,int b)
{
return a+b;
}
void f2(int (*f)(int,int),int a,int b) //'*f' is a POINTER TO A FUNCTION whose RETURN TYPE is                                                           //'int' and arg type (int,int)  . Here, '*f' is FORMAL PARAMETER
{
cout<<sum(a,b)<<endl;
}
int main()
{   int (*p1)(int,int)=∑          //Here, '*pf1' is ACTUAL PARAMETER
f2(sum,10,20);                         //NAME OF A FUNCTION IS ITSELF A POINTER TO ITSELF
f2(p1,20,79);
return 0;

}

Dislike Bookmark

Lesson Posted on 09/11/2017 Tuition/MTech Tuition Tuition/BTech Tuition/BTech Computer Science Engineering Tuition/BCA Tuition +2 Tuition/BSc Tuition/BSc Computer Science Tuition/Class XI-XII Tuition (PUC) less

GCC

Java 9 is here! A major feature release in the Java Platform Standard Edition is Java 9 Lets see what more it offers more than its previous versions Java platform module JEP 223 : New version string scheme Moreover it includes enhancements for microsoft windows and MAcOS OS platforms ... read more

Java 9 is here! A major feature release in the Java Platform Standard Edition is Java 9

Lets see what more it offers more than its previous versions

• Java platform module
• JEP 223 : New version string scheme

Moreover it includes enhancements for microsoft windows and MAcOS OS platforms

Dislike Bookmark

Looking for BSc Tuition

Find best BSc Tuition in your locality on UrbanPro.

FIND NOW

Lesson Posted on 23/08/2017 Tuition/BTech Tuition/BTech Computer Science Engineering Tuition/BSc Tuition/BSc Computer Science

SR - IT Academy is one of the leading tutorial point providing services like tutoring and computer training...

Choose the pivot (using the "median-of-three" technique); also, put the smallest of the 3 values in A, put the largest of the 3 values in A, and swap the pivot with the value in A. (Putting the smallest value in A prevents right from falling off the end of the array in the following steps.) Initialize:... read more
1. Choose the pivot (using the "median-of-three" technique); also, put the smallest of the 3 values in A[low], put the largest of the 3 values in A[high], and swap the pivot with the value in A[high-1]. (Putting the smallest value in A[low] prevents right from falling off the end of the array in the following steps.)
2. Initialize: left = low+1; right = high-2
3. Use a loop with the condition:

while (left <= right)

The loop invariant is:

all items in A[low] to A[left-1] are <= the pivot
all items in A[right+1] to A[high] are >= the pivot

Each time around the loop:

left is incremented until it "points" to a value > the pivot
right is decremented until it "points" to a value < the pivot
if left and right have not crossed each other,
then swap the items they "point" to.

1. Put the pivot into its final place.
Dislike Bookmark

Lesson Posted on 07/08/2017 Tuition/BTech Tuition/BTech Computer Science Engineering Tuition/BSc Tuition/BSc Computer Science

SR - IT Academy is one of the leading tutorial point providing services like tutoring and computer training...

Deadlocks in Distributed Systems: Deadlock can occur whenever two or more processes are competing for limited resources and the processes are allowed to acquire and hold a resource (obtain a lock) thus preventing others from using the resource while the process waits for other resources. Two common... read more

• If a young process wants a resource held by an old process, the young process will wait.

Dislike Bookmark

Lesson Posted on 05/07/2017 Tuition/BTech Tuition/Design & Analysis of Algorithms Tuition/BTech Tuition/BTech Computer Science Engineering Tuition/BTech Tuition/BTech Information Science Engineering +2 Tuition/BSc Tuition/BSc Computer Science Tuition/BCA Tuition less

Well, I love spending time with students and to transfer whatever computing knowledge I have acquired...

What is Complexity Analysis of Algorithm? Complexity Analysis, simply put, is a technique through which you can judge about how good one particular algorithm is. Now the term “good” can mean many things at different times. Suppose you have to go from your home to the Esplanade! There are... read more

What is Complexity Analysis of Algorithm?

Complexity Analysis, simply put, is a technique through which you can judge about how good one particular algorithm is.  Now the term “good” can mean many things at different times.

So what are the criteria while analyzing complexities of algorithms?

Focusing only on algorithms, the criteria are Time and Space. The criteria Time, judges how fast or slow the algorithms run when executed; and the criteria Space judges how big or small amount of memory (on primary/hard disks) is required to execute the algorithm. Depending on these two measuring criteria, two type of Algorithm Analysis are done; one is called Time Complexity Analysis and the second one is Space Complexity Analysis.

Which one is more important over the other?

I am sorry! I do not know the answer; rather there is no straight forward answer to this question. Think of yourself. Thinking of the previous example of many solutions that you have for travelling from your home to Esplanade, which criteria is most important? Is it Time of Travel, or is it Comfort? Or is it Financial Cost? It depends actually. While you are in hurry for shopping at New Market, the Time Taken would probably be your choice. If you have enough time in your hand, if you are in jolly mood and if you are going for a delicious dinner with your friends, probably you would choose Comfort; and at the end of the month, when you are running short with your pocket money, the Financial Cost would be most important to you.  So the most important criterion is a dynamic notion that evolves with time.

Twenty or thirty years back, when the pace of advancement of Electronics and Computer Hardware was timid, computer programs were forced to run with lesser amount of memory.  Today you may have gigantic memory even as RAM, but that time, thinking of a very large hard disk was a day dreaming! So at that time, Space Complexity was much more important than the Time Complexity, because we had lesser memory but ample times.

Now the time has changed! Now a day, we generally enjoy large memories but sorry, we don’t have enough time with us. We need every program to run as quick as possible! So currently, Time Complexity wins over Space Complexity.  Honestly, both of these options are equally important from theoretical perspective but the changing time has an effect to these.

Dislike Bookmark

Lesson Posted on 05/07/2017 Tuition/BTech Tuition/BTech Computer Science Engineering Tuition/BTech Tuition/BTech Information Science Engineering Tuition/BSc Tuition/BSc Computer Science +1

Well, I love spending time with students and to transfer whatever computing knowledge I have acquired...

There are two variants of #include. The one is #include and the other one is #include”file”. In general the first form that is #include is used to include system defined header files which are searched in the standard list of system directories. The second form i,e #include”file”... read more

Both the forms of #include share a common property that is no escape sequence or commenting  styles are recognized within or “file”. What I mean to say is that if I write #include <x/*y>, that means I want to include a file named x/*y.  Similarly writing #include<x\y\\z> is also perfect if the file x\y\\z is needed to be included.

Dislike Bookmark

Lesson Posted on 05/07/2017 Tuition/BTech Tuition/BTech Computer Science Engineering Tuition/BTech Tuition/BTech Information Science Engineering Tuition/BCA Tuition +1 Tuition/BSc Tuition/BSc Computer Science less

Well, I love spending time with students and to transfer whatever computing knowledge I have acquired...

The difference is indeed very thin and it depends on the context. In general Function is a piece of code with a name, inputs (arguments) and an output (return types). That is function should always return. Some programming languages are there which uniquely maps inputs to the corresponding outputs. But... read more

Subroutine is just a piece of any sorts of code with a definite entry and exit point. It should not return anything and a subroutine can always change global variables. These are generally used for conceptual purposes like in psudocodes.

Dislike Bookmark

Lesson Posted on 05/07/2017 Tuition/BTech Tuition/BTech Computer Science Engineering Tuition/BTech Tuition/BTech Information Science Engineering Tuition/BCA Tuition +1 Tuition/BSc Tuition/BSc Computer Science less

Well, I love spending time with students and to transfer whatever computing knowledge I have acquired...

Are reference and pointers same? No. I have seen this confusion crumbling up among the student from the first day. So better clear out this confusion at thevery beginning. Pointers and reference both hold the address of other variables. Up to this they look similar, but their syntax and further consequences... read more

Are reference and pointers same?

No.

I have seen this confusion crumbling up among the student from the first day. So better clear out this confusion at thevery beginning.

Pointers and reference both hold the address of other variables. Up to this they look similar, but their syntax and further consequences are totally different. Just consider the following pieces of code

Code 1                                         Code 2

int i;                                             int i;

int *p = &i;                                 int &r = i ;

Here in code 1 we have declared and defined one integer pointer p which points to variable i, that is now , p holds the address of i.

In code 2, we have declared and defined one integer reference r which points to variable i, that is now, r holds the address of i. This is completely same as that of p.

So where is the difference?

The first difference can be found just by looking at the code. Their syntaxes!

Secondly the difference will come up when they would be used differently to assign a value (suppose 10) to i.

If you are using a pointer, you can do it like *p = 10; but if you are using a reference, you can do it like r = 10.  Just be careful to understand that when you are using pointers, the address must be dereferenced using the *, whereas, when you are using references, the address is dereferenced without using any operators at all.

This notion leaves a huge effect as consequences. As the address of the variable is dereferenced by * operator, while using a pointer, you are free to do any arithmetic operations on it. That is you can increment the pointer p to point to the next address just by doing p++. But, this is not possible using references.  So a pointer can point to many different elements during its lifetime; where as a reference can refer to only one element during its life time.

Does C language support references?

No. The concept of reference has been added to C++, not in C. So if you run the following code, C compiler will object then and there.

#include

#include

int main(void)

{

int i;

int &r = i;

r = 10;

printf("\n Value of i assigned with reference r = %d",i);

getch();

return 0;

}

But if you are using any C++ compiler, this code will work fine as expected.

If there is no concept of reference in C language, then how come there exists C function call by reference?

Strictly speaking, there is no concept of function call by reference in C language. C only supports function call by value. Though in some books ( I will not name any one) it is written that C supports function call by reference or the simulation of  function call by reference can be achieved through pointers, I will strongly say that C language neither directly supports function call by reference, nor provides any other mechanism to simulate the same effect.

I know you are at your toes to argue that what about calling a C function with address of a variable and receiving it with a pointer? The change made to that variable within the function has a global effect. How this cannot be treated as an example of function call by reference?

You probably argue with a code like following

#include

#include

void foo(int* p)

{

*p = 5;

printf("\n Inside foo() the value of the variable: %d",*p);

}

int main(void)

{

int i = 10;

printf("\n before calling  foo() the value of the variable: %d",i);

foo(&i);

printf("\n after calling  foo() the value of the variable: %d",i);

getch();

return 0;

}

Your code will show the result as

Your points are well taken. But the thing is what you are showing is not at all calling a function by reference. It just the function call by value! Here you are essentially copying the value of address of your variable i and calling the function foo with that copy. Now eventually in this case, the value that is being passed contains the address of another variable. Within the function, you are accepting this value with a pointer and changing the value of the content addressed by that pointer. So it is nothing but a function call by value only.

Please note that to change the value of the content addressed by a pointer, you are to use *, no way could it be thought of as a reference.

Now let me give you one example of true function call by reference

#include

#include

void foo (int& r1)

{

r1 = 5;

printf("\n Inside foo() the value of the variable: %d", r1);

}

int main(void)

{

int i = 10;

int &r = i;

printf("\n before calling  foo() the value of the variable: %d",i);

foo(r);

printf("\n after calling  foo() the value of the variable: %d",i);

getch();

return 0;

}

Will this run with your C compiler? No.

Note:: I have used DevC++ as the coding platform

Dislike Bookmark

Looking for BSc Tuition

Find best BSc Tuition in your locality on UrbanPro.

FIND NOW

Lesson Posted on 05/07/2017 Tuition/BTech Tuition/BTech Computer Science Engineering Tuition/BTech Tuition/BTech Information Science Engineering Tuition/BCA Tuition +1 Tuition/BSc Tuition/BSc Computer Science less

Well, I love spending time with students and to transfer whatever computing knowledge I have acquired...

What is a void pointer? Void pointer is a special type of pointer which can reference or point to any data type. This is why it is also called as Generic Pointer. As a void pointer can point to any data type, neither it is possible to dereference a void pointer, nor is it possible to do any arithmetic... read more

To deal with this, to be in safer side, we must have the scope of the variable intact out of the function call; declaring it as static might be an option.

Dislike Bookmark

UrbanPro.com helps you to connect with the best BSc Tuition in India. Post Your Requirement today and get connected.

Overview

Lessons 29

Total Shares

63,483 Followers

Top Contributors

Connect with Expert Tutors & Institutes for BSc Computer Science

BSc Tuition in:

x

X

Looking for BSc Tuition Classes?

Find best tutors for BSc Tuition Classes by posting a requirement.

• Post a learning requirement
• Get customized responses
• Compare and select the best

Looking for BSc Tuition Classes?

Find best BSc Tuition Classes in your locality on UrbanPro

UrbanPro.com is India's largest network of most trusted tutors and institutes. Over 55 lakh students rely on UrbanPro.com, to fulfill their learning requirements across 1,000+ categories. Using UrbanPro.com, parents, and students can compare multiple Tutors and Institutes and choose the one that best suits their requirements. More than 7.5 lakh verified Tutors and Institutes are helping millions of students every day and growing their tutoring business on UrbanPro.com. Whether you are looking for a tutor to learn mathematics, a German language trainer to brush up your German language skills or an institute to upgrade your IT skills, we have got the best selection of Tutors and Training Institutes for you. Read more