A

@aabouqas

cpp

C++
2 years ago
#include <iostream> using namespace std; #define size 10 int stack[10]; int top = -1; void push(int value){ if (top == size - 1){ cout << "the stack is full" << endl; } else { top++;

prttttttttttttttt

C
2 years ago
#include <stdio.h> #include <stdarg.h> void print(char *format, ...) { va_list list; va_start(list, format); int i = 0; int c = 0; while (format[i])

word count

C
2 years ago
#include <stdio.h> #include <stdbool.h> #include <stdlib.h> #include <string.h> typedef struct { int val1; int val2; }twoValues; int len(char *str){ int count = 0;

nodes

C
2 years ago
#include <stdio.h> #include <stdlib.h> typedef struct node{ char *name; struct node *next; } node; void addNode(node **start, char *str) { node *newNode = malloc(sizeof(node));

word count

C
2 years ago
#include <stdio.h> int space(char c) { return (c <= 32); } int wordcount(char *str) { int count = 0; int word = 0;

lattttterrrr

C
2 years ago
#include <stdio.h> void splitString(const char *str, const char delimiter) { char substr[100]; int substr_idx = 0; for (int i = 0; str[i] != '\0'; i++) { if (str[i] == delimiter) { substr[substr_idx] = '\0'; printf("%s\n", substr);

llltttt

C
2 years ago
#include <stdio.h> #include <stdlib.h> int length(char *str) { if (*str) return 1 + length(str + 1); return 0; } char *ft_strncpy(char *dest,char *src,int size) {

struc

C
2 years ago
#include <stdio.h> typedef struct { char name[20]; int id; } user; void show(user u) { printf("%s", u.name); }

lt

C
2 years ago
#include <stdio.h> int main() { int i; int ii = 1; while (ii <= 5) { i = 1; while (i <= 10) {

students

C
2 years ago
#include <stdio.h> typedef struct s_student { char *name; int age; float point; }t_student; void ft_swap(t_student *a, t_student *b) { t_student temp;

*ft_strs_to_tab

C
2 years ago
#include <stdio.h> #include <stdlib.h> typedef struct s_stock_str { int size; char *str; char *copy; } t_stock_str; int length(char *str) {

next prime

C
2 years ago
#include <stdio.h> int ft_is_prime(int nb) { int i; i = 2; if (nb < i) return (0); while (i < nb / i) {

cced

C
2 years ago
#include <stdio.h> #include <stdlib.h> int length(char *str) { if (*str) return (1 + length(str + 1)); return (0); }

arg sort

C
2 years ago
#include <stdio.h> #include <unistd.h> void print(char *s) { if (*s) { write (1, s, 1); print(s + 1); }

sort

C
2 years ago
#include <stdio.h> void ft_sort(int array[], int size) { int i = 0; size -= 1; while (i < size) { int ii = 0; while (ii < size) {

lennn

C
2 years ago
#include <unistd.h> #include <stdio.h> void print(char *str) { if (*str) { //print(str + 1); write (1, str, 1); print(str + 1); }

swap

C
2 years ago
#include <stdio.h> void swap(char **s1, char **s2) { char *temp; temp = *s1; *s1 = *s2; *s2 = temp; } int main() { char *s1 = "aissam";

prt v2

C
2 years ago
#include <stdio.h> int length(char *str) { int i = 0; while (str[i]) i++; return i; } int main() { int i = 0;

alpha

C
2 years ago
#include <unistd.h> void alpha(char c) { if (c < '9') { write(1, &c, 1); alpha(c+1); } } int main() {

ltr

C
2 years ago
#include <stdio.h> #include <unistd.h> void print(char c) { if (c >= 0 && c <= 9) { c = c + '0'; write (1, &c, 1); } else {