Thursday 4 January 2018

Learn C language Part 28 String Introduction in C Language



#include <stdio.h>

#include <conio.h>



main()

{



char c[]="abcd\\ndef";

char d[4]="abc";



char e[] = {'a', 'b', 'c', 'd', '\0'};

     OR,

char f[5] = {'a', 'b', 'c', 'd', '\0'};



printf("%s",&c);



printf("\n%s",&d);







}


Learn C language Part 27 Function by reference





#include <stdio.h>

#include <conio.h>



void calculator(float a,float b,float *plus,float *diff, float *product, float *divide);



main()

{



float add,sub,mul,div;

float a=32.1, b=10.9;

calculator(a,b,&add,&sub,&mul,&div);



printf("Sum = %f\n",add);

printf("Difference = %f \n",sub);

printf("Product = %f \n",mul);

printf("quotient = %f \n",div);









}



void calculator(float a,float b,float *plus,float *diff, float *product, float *divide)

{

*plus= a+b;

*diff= a -b;

*product=a*b;

*divide=a/b;



}


Pass Dynamically Added Html Table Records List To Controller In Asp.net MVC

Controller Code: using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.Mvc; using ...