Join the social network of Tech Nerds, increase skill rank, get work, manage projects...
 

how to run this program in do while loop

Hi, I want to run the below program in do while loop, please help me. #include<stdio.h> int main() { int num; char another; do { printf("enter the number"); scanf("%d", &num); printf("the square is %...

How to calculate the ranking for students in a classroom using arrays only and sorting techniques

Hi there. I have a task to Calculate the ranking for students in a classroom. For example, if Remi's score is 14, Yan's score is 2 and Maria's score is 20 then Remi's ranking is 2 since he has the second-highest score, ...

How to fix my code in C language programming

Hello i am doing an exercise that states:  A 3000 lb  vehicle travelling on a road at 100 ft/sec requires a force equal to its mass times its acceleration to stop ( F = ma). The acceleration is given by a=  (v_o^2-v_i^2)/2...

Complex Software Algorithm Problem (Java/C#)

Hi,   Can someone please assist in solving the attached complex software algorithm problem as attached (using Java or C#)   Thank you in advance

How to Sort Names in Alphabetical Order Using Bubble Sort in C Program

Could someone help me write a C program that would let users to input names in any order, then displays the names, sorted in Alphabetical order. You may use any sorting algorithm like Bubble Sort, Selection Sort, Insertion Sort, et...

How to Get Root Node Deleted Properly in Binary Search Tree

#include<stdio.h> #include<stdlib.h> struct node {   struct node *right;     int data;   struct node *left; }*root=NULL,*new,*temp; int num=0,num1; void insert(); struct node *del(struct node *...

How to Write popen() Simulating Function in C Programming?

Hi Friends!   I have a difficulty with a recent task. I have a very little programming experience and although I got myself familiar with each function and understand what each does, I can't somehow compose them together to a ...

return address of local variable or array

in this code I am trying to return the address of local array(c[100]) ,complier was showing me error of returning address of local variable but when changed the datatype from int to static int it works fine.whats the reason behind this? #inclu...

Appropriate Partitioning

Given an array A of integers, choose 2 non-empty disjoint subsets X and Y such that ratio of sum of elements of X and Y is as close to 1 as possible. Given, Α : {a1, a2, .... aN} Find, X : {x1, x2....xK} Y : {y1, y2.....yM} ...

Memory Leak detection Program

Hello!! A Memory leak occurs when we did not manage the memory allocation in the programs, it is the type of resource leak. Memory leak reduces the performance because it reduces the memory of the system. It is common in those l...

C Program to Display the IP Address of the System

Hello Everyone, In this blog, We are going to know that how to display the ip address of the system using c programming. We can find the IP address, Gateway, Subnet Mask by typing ipconfig in command prompt. Here we are going to...

Parallel Arrays

Create a program that allows the user to input a list of first names into one array and last names into a parallel array. Input should be terminated when the user enters a sentinel character. The output should be a list of email address...

c program to print all possible combinations of given input number or value ?

If user input is 183 then output should be 183 138 813 831 318 381.

I need help in a C code

Help me with the Logic of the question given below: You will be given a file with two lines. First line will contain two integers separated by commas(say X,Y). In the next line there will be Y number of integers again separated by commas. You ...

Sorting singly linked list which takes only one argument

I want to write a recursive method which sorts the singly linked list and takes only one argument. And do not write another auxiliary method to support this recursive method.

Arithmetic operations by using only one variable

Hey Guys, Today we are going to perform Arithmetic operations by using only one variable. It means, if we have define a single variable for loops or anything else then it must be used for all the operation. So, here, your only friend is ...

Program in c to print 1 to 100 without using loop

in this program of C language we are not using the any king of loop,we are printing the numbers without loop. #include int main(){ int num = 1; print(num); //it is a function which is calling the value of pri...

How to convert string to int without using library functions in c

here we are converting string values to the integer without using library functions. #include int stringToInt(char[] ); int main(){ char str[10]; int intValue; printf("Enter any integer as a string:...

A program to find out NCR factor of given number in C language

ncr means : combination in terms of mathematics.We have to find out the perfect combination of given values. In the mathematics nCr has defined as nCr = n! /((n-r)! * r!) #include int main(){ int n,r,ncr; printf("Ente...

program to find out generic root of any number on C language

generic root means: in this we do addition of a given number until reached a single digit after addition . For example: Generic root of 784: 7 + 8 + 4 = 19 since 19 is a two digit numbers so 1 + 9 = 10.then again add 1 +0=1 So, ge...

PROGRAM TO SUBTRACT TWO NUMBER WITHOUT USING SUBTRACTION OPERATOR

A program on C language without using subtraction operator is done by taking the numbers 2's complement and then add it to another number. #include<stdio.h> int main(){ int a,b; int sum; int complement=0; prin...

A program to count the different types of characters in given string

counting of different characters is done by using strlen(i.e string length) and arr denotes array. We use for loop to pass the ASCII code of alphabets from a to z. #include<stdio.h> #include<string.h> void main() ...

For Loop in C

For Loop: allow us to efficiently write a loop that needs to be executed specific number of times. Syntax: for(init statement; test expression; increment) { code(s) to be executed; } The init statement allow us to initia...

File handling operation in c language

File handling in C In C programming language we use a structure pointer of file type for declaring a file. Syntax:- FILE *fp; The fopen() function is used to create a new file or to open existing file. Syntax : *fp = FILE *fo...

Arrays in C

An array is a homogeneous collection of data. An array is a container that stores a fixed number of values of same type. The length of array is specified when we create an array. Once created, its legth is fixed. We can think of array as a struct...

Command line argument

Command Line Argument 1. Command line argument is a way of supplying parameter to the program whenever it is invoked. In command line argument when user call main method it is called by two arguments.The first is the number of command-line ar...

Recursion in c

In C programming language when a function calls itself over and over again , that function is called recursive function .The process of function calling itself repeatedly is known as recursion . Recursion is supported by C programming languag...

union in C

A union is a special data type available in C that allows to store different data types in the same memory location just like structures in C. Union uses a single shared memory location which is equal to the size of its largest data member. It...

Diiference Between C and C++

Basic difference between C and C++: C C++ C follow procedural programming language C++ follow procedural and object oriented ...

Encrypt a message

I have to write a function to encrypt a message given as a string input using the given encryption key. The function should output the encrypted message as a string to encryptedMessage in the argument list. The function prototype must be as fol...

C programming encrypting a message

Hey guys, i am a C programming beginner and looking for help urgently. I need to Write a function to encrypt a message given as a string input using the given encryption key. The function should output the encrypted message as a string to enc...

Implement Quick Sort using C

Quick Sort Algorithm:- Quick sort is the most famous sorting algorithm. It is the external sorting technique that is based on divide and conquer strategy. The Complexity of this algorithm is following: Best Case:- O(n log n) Average Case:- O...

Implement Bubble Sort Using C

Bubble Sort:- Bubble Sort is the one of most popular Sorting Algorithm that is used to sort the array of n size. The Worst case and Average Case Complexity of Bubble Sort is O(n)^2. The Below Code will show you how to implement the bubble sort to...

Implement Binary Search Using C

Binary Search:- The Binary Search is one of the most important searching technique in Searching Algorithm. The one of property of this searching algorithm is, all the elements are in sorted order in array. The worst case and average case complexi...

Implement Doubly LinkList Using C

Doubly Linklist:- In Singly Linklist we have to move only in forward direction. we don't move in backward direction in linklist but Using Doubly Linklist we can iterate in both forward and backward direction. The Below code will shown you how to...

Sorting In Linklist

Sorting inside Linklist:- This Blog will show you, how to create a sorted linklist. By using that can achieve the Sorting inside our Linklist. The Element will Enter inside Linklist in Sorted Manne. #include<stdio.h> #include<conio...

Insertion in Linklist at Different Places

Insertion in Linklist:- The Insertion of Element in Singly linklist at different places like: insertion at beginning, last and middle in the linklist. In below code I will show you how to insert the element in linklist at beginning, middle and la...

Implementation of Singly Linklist in C

Singly Linklist:- Hii Friends, The Below code will show you how we can create singly Linklist in Data Structure using C. we can simply create the singly linklist using the pointers and malloc function to insert and delete element dynamically. ...

Implement Queue Using Dynamic LinkList

Queue using Dynamic LinkList:-The Below code can shown you how to implement Queue using dynamic linklist in data structure using C. We can insert the node dynamically and the Linklist works on principal First-In-First-Out(FIFO). The Element can s...

Implementation of Insertion Sort in C

Insertion Sort:- The Insertion sort is used to sort an array. The array can be sorted in each round means, In each Iteration of an array the element can be find in sorted. Steps:- 1: The second element of array compared with the elements w...

c programming error codes

can any body tell me c programming error codes i am not able to understand the things

Difference between variable declaration globally and locally

During my project work I was working on a code in which I was getting segmentation fault on initialization of two variables of float data type whose dimensions where 1000 cross 1800 for both of them, but when I declared the variables globally pro...

Comparing float with a value

Hi everyone, I was looking at two C programs given here below, attached in the question.txt file. I can't write my code here because in the preview section my code looks very ambiguous. These codes are giving different outputs but i was thinki...

Floyd cycle detection

Can anybody tell me the complexity of Floyd cycle detection algorithm in singly linked list with proof.
Sign In
                           OR                           
                           OR                           
Register

Sign up using

                           OR                           
Forgot Password
Fill out the form below and instructions to reset your password will be emailed to you:
Reset Password
Fill out the form below and reset your password: