new_instruction2
stringlengths
155
411
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Write a program in C that prints a number pattern in the shape of a hollow square.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Write a program in C that prints a number pattern in the shape of a hollow right-angled triangle.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Write a program in C that prints a number pattern in the shape of a hollow diamond.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Write a program in C that prints a number pattern in the shape of an inverted hollow right-angled triangle.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Write a program in C that prints a number pattern in the shape of a hollow pyramid.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Write a program in C that prints a number pattern in the shape of a butterfly.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Write a program in C that prints a binary number pattern in the shape of a right-angled triangle.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Write a program in C that prints a binary number pattern in the shape of a pyramid.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Write a program in C that prints a binary number pattern in the shape of a diamond.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Write a program in C that prints a binary number pattern in the shape of a hollow square.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Calculates the size of a variable using the `sizeof` operator.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Copies the contents of one string to another using the `strcpy` function.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Concatenates two strings using the `strcat` function.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Reverses a given string using a loop and pointers.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Searches for a character in a string using the `strchr` function.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Compares two strings and returns 0 if they are equal using the `strcmp` function.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Sets all elements in an array to a specific value using the `memset` function.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Allocates memory dynamically for an integer variable using the `malloc` function.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Frees previously allocated memory using the `free` function.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Copies a block of memory from one location to another using the `memcpy` function.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Takes input from the user and stores it in a character array using the `fgets` function.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Calculates the length of a string without using any string functions.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Converts a string to an integer using the `atoi` function.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Allocates memory for a structure using the `calloc` function.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Swaps the values of two integer variables using pointers.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Checks if a given string is a palindrome or not.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Computes the factorial of a number using recursion.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Converts an integer to a binary string representation.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Counts the occurrence of a specific character in a string.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Checks if a string is a valid integer or not.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Finds the maximum element in an array using pointers.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Counts the number of words in a sentence.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Reverses the elements of an array in place.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Inserts an element at a specific position in an array.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Calculates the sum of all elements in an array.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Counts the number of characters in a given string.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Copies one string to another.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Concatenates two strings.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Checks if two strings are equal.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Finds the length of a string without using library functions.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Converts a string to uppercase.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Converts a string to lowercase.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Reverses a given string.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Checks if a string is a palindrome.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Removes spaces from a given string.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Counts the number of vowels in a string.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Counts the number of consonants in a string.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Replaces all occurrences of a character in a string with another character.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Checks if a string contains a specific substring.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Finds the first occurrence of a character in a string.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Removes the last occurrence of a specific character in a string.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Sorts the characters in a string in alphabetical order.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Performs a case-insensitive comparison of two strings.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Inserts a string into another string at a specific position.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Trims leading and trailing spaces from a string.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Extracts a substring from a given string.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Checks if a string is empty.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Converts a string to a integer.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Converts a string to a floating point number.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Splits a string into multiple substrings using a delimiter.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that declares a function pointer fptr which points to a function that takes no arguments and returns void.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that declares a function pointer fptr which points to a function named add that takes two integers as arguments and returns their sum.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named multiply which takes two integers as arguments and returns their product.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named printHello which takes no arguments and returns void. The function should print "Hello!" to the console.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named greet which takes a string as an argument and prints "Hello, <string>!" to the console.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named power which takes two integers as arguments: base and exponent. The function should calculate and return base raised to the power of exponent.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named isEven which takes an integer as an argument and returns 1 if it is even, and 0 otherwise.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named multiplyByTwo which takes an integer pointer as an argument and multiplies the value it points to by Write a program in C that
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named swap which takes two integers as arguments and swaps their values.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named findMax which takes an array of integers and its size as arguments. The function should return the maximum value in the array.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named findMin which takes an array of integers and its size as arguments. The function should return the minimum value in the array.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named stringLength which takes a string as an argument and returns its length.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named findAverage which takes an array of integers and its size as arguments. The function should return the average value of the array.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named isPrime which takes an integer as an argument and returns 1 if it is prime, and 0 otherwise.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named printArray which takes an array of integers and its size as arguments. The function should print all the elements of the array.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named reverseString which takes a string as an argument and reverses it.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named sumArray which takes an array of integers and its size as arguments. The function should return the sum of all the elements in the array.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named convertToUpper which takes a string as an argument and converts all its characters to uppercase.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named divideByTwo which takes an integer pointer as an argument and divides the value it points to by Write a program in C that
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named findIndex which takes an array of integers, its size, and a target value as arguments. The function should return the index of the target value in the array, or -1 if it is not found.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named calculateFactorial which takes an integer as an argument and returns its factorial.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named printOddNumbers which takes an array of integers and its size as arguments. The function should print all the odd numbers in the array.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named isPalindrome which takes a string as an argument and returns 1 if it is a palindrome, and 0 otherwise.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named findStringLength which takes a string as an argument and returns its length, without using the standard strlen() function.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named countVowels which takes a string as an argument and returns the number of vowels in it.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that declares a function pointer fptr and assigns it to a function named reverseArray which takes an array of integers and its size as arguments and reverses the order of the elements.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Creates an integer pointer and assigns the address of an integer variable to it.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Increments the value of the integer variable by using pointer arithmetic.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Decrements the value of the integer variable by using pointer arithmetic.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Adds two integers together using pointer arithmetic.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Subtracts two integers using pointer arithmetic.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Multiplies two integers using pointer arithmetic.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Divides two integers using pointer arithmetic.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Finds the remainder of dividing two integers using pointer arithmetic.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Assigns the value of one pointer variable to another pointer variable.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Prints the address of a pointer variable using pointer arithmetic.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Prints the value of a pointer variable using pointer arithmetic.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Swaps the values of two integer variables using pointer arithmetic.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 3[/INST] Write a program in C that Prints the elements of an array using pointer arithmetic.
The conversation between a Human and AI Assistant [INST] Generate a C programming question exam in PART – A section, for 6[/INST] Write a program in C that Copies the contents of one array to another using pointer arithmetic.