EmbLogic's Blog

Category Archives: Data Structures with C

structure problem

i want to initialise structure array only when needed. what to do

Posted in Data Structures with C | Leave a comment

why value are not reading trough scanf

#include<stdio.h> int main() { double a,b,c; printf(“Enter the temprature in fahrenheit “); scanf(“%e”,&a); c=1.8*a+32; b=1.8*a+32+273.16; printf(“the conversion in fahrenheite %e celcius is %3.2e and is %6.2\n”,a,c,b); return 0; } i  am reading the value through scanf and storing the value … Continue reading →

Posted in Data Structures with C | 1 Comment

why printf giving value without using variable name

int ten = 10; int two = 2,z=3; printf(“Doing it right: “); printf(“%d minus %d is %d \n”,ten,2,ten-two); printf(“Doing it wrong: “); printf(“%d minus %d is %d\n”,ten); // In this function i have not used the variable name “ten” then … Continue reading →

Posted in Data Structures with C | Leave a comment

issues with question 18 of assgn1

#include<stdio.h> int main() { long double mwt = 3.0e-23; printf(“%LF”,mwt); return 0; } why o/p is ./seventeen 0.000000 root@linuxstation asgmt#

Posted in Data Structures with C | 1 Comment

[Query][Assignment 2] Unexpected output

For the third question in the second assignment, the output has an extra character ‘S’ printed. This indicates that the switch case with the value ’9′ was run. But there is no apparent code that puts 9 to the value … Continue reading →

Posted in Data Structures with C | Leave a comment

5 stages of compiler

Compilation process in general is split into roughly 5 stages and those are as follows:- 1. Preprocessing 2. Parsing 3. Translation 4. Assembling 5. Linking

Posted in Data Structures with C | 1 Comment

Assignment 1

Completed assignment 1, started second assignment  

Posted in Data Structures with C | 1 Comment

To Pravjot Sir : Compilation steps for a C code

Compilation Steps  For a Hello World program : #include<stdio.h> int main() { printf(“Hello World \n”); return 0; } Step One :The C preprocessor implements the macro language used to transform C,C++, and Objective-C programs before they are compiled. aregee@linuxstation src_projects$ … Continue reading →

Posted in Data Structures with C | 2 Comments

Regarding project

successfully completed the master array working on assignment 1

Posted in Data Structures with C | Leave a comment

master array done..working on assignment-1

Posted in Data Structures with C | Leave a comment

comlement of 1′s

why 1′s complement of 1 = -2, not -1 ?

Posted in Data Structures with C | 1 Comment

int main() { int value=100; printf(“value in decimal is:%d\n”,value); printf(“value in hexa is:%x\n”,value); printf(“value in octal is:%o\n”,value); return 0; } in this program i m getting the following error undefined reference to print ld returned 1 exit status how can … Continue reading →

Posted in Data Structures with C | 4 Comments

various functions made

#include #include #include //int debug(const char*,const char*[10],char*); int say(char*); int say_num(int*); int* sum(int*,int*); int fact(int); int find_addr(); int back(); int main() { printf(“%s -> %p”,__func__,&__func__); char *b=”hello world”; char c[]=”humpty dumpty sat on a wall”; int d[]={1,2,3,4,5,6,7,8,9,0}; printf(“\n%d”,say(b)); printf(“\n%d”,say_num(d)); printf(“\n%d”,*(sum(d+1,d+2))); … Continue reading →

Posted in Data Structures with C | Leave a comment

Asssignment status

assignment 1 and 2 completed. looking forward to make notepad like program using FILE I/O

Posted in Data Structures with C | Leave a comment

Related to standard header files

which command prompt can display all the header files of stdio.h?

Posted in Data Structures with C | Leave a comment