EmbLogic's Blog

Project 11: Linux Shell Scripting

Implemented

# Linux shell scripting questions.

Posted in Uncategorized | 1 Comment

Project4:Client Server using Sockets(AF_UNIX)

Implemented

#Client Server using AF_UNIX on my PC and ran 370 simultaneous threads

 

Posted in Uncategorized | Leave a comment

what its output & why

{
int i, j, k;
i = -1;
j = 1;
k = 1;
++i && j++ || ++k;
printf(“%d %d %d\n”,i,j,k);

return 0;

Posted in Uncategorized | Tagged | 5 Comments

Project 1(status)

Just completed assignment 3,,

Posted in Data Structures with C | Leave a comment

Project 01

Completed assignment 3…But Still  i do have a no. of doubts.

Posted in Data Structures with C | 1 Comment

project 1

done assignment no. 3 except Q.8 i have following problems

Q.5char to = 1,from = 2;

to++ = from++;

error is :lvalue required as left operand of assignment

Q.4

float f=0.1f;int i;

for(i=0;i<10;i++)

f=f+0.1f;

if(f==1.0f)

this if condition should be true as on printing the value of f using %f format specifier shows 1.000000.but in program  it is taken as false.WHY????

 

Posted in Data Structures with C | Leave a comment

Project 1

Done assignment 2,Q:7(checking a number for power of 2) using single expression.

done 8 questions from 3rd assignment ,having problem in Q5:showing errors in assignment statements like

i++=j++;

and in Q8(print cycle of sine and cosine wave),i don’t understand what to do in program;

overall enjoying C…..

 

Posted in Data Structures with C | Leave a comment

Thread assignment

Completed thread assignment…!!

Posted in Uncategorized | Leave a comment

Behaviour of printf function

int i=0;
printf(“%d\t%d\t%d\t%d\t%d\t%d\t%d\n”,i++,++i,i++,++i,i,i++,i);

What will be the output? And how?

Posted in Uncategorized | 2 Comments

Project 4 : Client-Server Program Using Threads

Implemented Client Server Program using Threads,Mutex,Message Queues,Fifo. In this program each thread is created at server side for each request from requesting client. Implemented for 250 clients.

 

 

Posted in Uncategorized | 1 Comment

Float storage

I don’t know how floats are stored.
e.g. 1.216
how will it be stored?
as 1.216e0 or 0.1216e1 or 0.0126e2 or 12.16e-1 ……?

Posted in Uncategorized | Leave a comment

thread: assignment

assignment completed using mutex and semaphore both.

Posted in Uncategorized | Leave a comment

Project 4: Client Server Program Using Threads, Mutex,Semaphore,Msg Queue

Implemented
#The client server program using thread, mutex,semaphore and msg queue. In the program created thread for each request from the client and at client side created 1 thread for sendg and receiving different requests.. Program ran for 381 clients and then hangs..
Issues Faced::
1)When running simultaneous clients>5 in the background the  output of some client reaching some other client.Not able to successfully run more than 5 threads on my PC in parallel…. Resolved by sleep(1)..

Faced problem 1) because was using pipes for processing clients and the was using 1 mutex for each processing client and the mutex were locked and unlocked in the child and parent process respectively. This was creating a problem as the client was working on a copy of mutex… Solved by locking the mutex before fork()
2)Couldnt implement the above program using fifo as different clients take each others data so used queues and specified type for each client..found FIFO unsuccessful to implement client server using thread

Posted in Uncategorized | Leave a comment

project 1

7 questions completed of assisgnment 1

Posted in Uncategorized | Leave a comment

project 1

i have completed assignment no 1 with some problems.

Posted in Uncategorized | Leave a comment