C language basic to Advance pinned «20 questions related to c loops https://t.me/C_Codes_pro/184 Answers 🔥 (can run also) https://t.me/C_Codes_pro/212 Your 10 to 30 numbers is final in c if you practice these 20 questions»
🥰1
Select your group/channel/service
t.me/Sid_info/69
t.me/Sid_info/69
🥰1
// udp server program
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/socket.h>
#include <netinet/in.h>
#define PORT 8888
#define MAX_BUFFER_SIZE 1024
int main() {
int sockfd;
struct sockaddr_in serverAddr, clientAddr;
socklen_t addrLen = sizeof(clientAddr);
char buffer[MAX_BUFFER_SIZE];
// Creating socket file descriptor
if ((sockfd = socket(AF_INET, SOCK_DGRAM, 0)) == -1) {
perror("Socket creation error");
exit(EXIT_FAILURE);
}
memset(&serverAddr, 0, sizeof(serverAddr));
memset(&clientAddr, 0, sizeof(clientAddr));
serverAddr.sin_family = AF_INET;
serverAddr.sin_addr.s_addr = INADDR_ANY;
serverAddr.sin_port = htons(PORT);
// Bind the socket to the specified port
if (bind(sockfd, (const struct sockaddr *)&serverAddr, sizeof(serverAddr)) == -1) {
perror("Bind error");
exit(EXIT_FAILURE);
}
printf("UDP server running on port %d\n", PORT);
// Receive data from clients indefinitely
while (1) {
int bytesReceived = recvfrom(sockfd, (char *)buffer, MAX_BUFFER_SIZE, 0, (struct sockaddr *)&clientAddr, &addrLen);
buffer[bytesReceived] = '\0'; // Null-terminate the received data
printf("Received message from client: %s\n", buffer);
}
return 0;
}
👍2🤬2❤1
// udp client program
/*
If you want run udp server and client program here then use 2 telegram id
First run udp server program from 1st id
Then run udp client program from second id
Otherwise it will give error
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/socket.h>
#include <netinet/in.h>
#define PORT 8888
#define SERVER_IP "127.0.0.1"
int main() {
int sockfd;
struct sockaddr_in serverAddr;
char *message = "Hello, UDP Server!";
// Creating socket file descriptor
if ((sockfd = socket(AF_INET, SOCK_DGRAM, 0)) == -1) {
perror("Socket creation error");
exit(EXIT_FAILURE);
}
memset(&serverAddr, 0, sizeof(serverAddr));
serverAddr.sin_family = AF_INET;
serverAddr.sin_port = htons(PORT);
serverAddr.sin_addr.s_addr = inet_addr(SERVER_IP);
// Send a message to the server
if (sendto(sockfd, (const char *)message, strlen(message), 0, (const struct sockaddr *)&serverAddr, sizeof(serverAddr)) == -1) {
perror("Sendto error");
exit(EXIT_FAILURE);
}
printf("Message sent to server: %s\n", message);
close(sockfd);
return 0;
}
/*
If you want run udp server and client program here then use 2 telegram id
First run udp server program from 1st id
Then run udp client program from second id
Otherwise it will give error
*/
👍6
Everything related to coding 👇
https://t.me/addlist/2UhsQW_cGzkxMzg1
https://t.me/addlist/2UhsQW_cGzkxMzg1
Apna khud ka Compiler bot run karna ab bahut simple hai
Bas iocompiler lib install karo aur code run kardo 👇ye dekho poori details
https://t.me/logicBots/207
Bas iocompiler lib install karo aur code run kardo 👇ye dekho poori details
https://t.me/logicBots/207
👍3
C language
https://youtu.be/GPat5ENZytg
C language samajhane ke liye har tarah ka prayas 👇
By defination
By real life example
By in deep memory how c works
By codes examples
By practical code run
https://youtu.be/GPat5ENZytg
C language samajhane ke liye har tarah ka prayas 👇
By defination
By real life example
By in deep memory how c works
By codes examples
By practical code run
👍4🥰2❤1
Create compiler bot in mobile
Run any language codes
In hindi:
Ab laptop ko kar do Tata bye bye gya 😂
https://youtu.be/352o8B9IikI?si=OSrhBU0mcFEkqILA
Run any language codes
In hindi:
Ab laptop ko kar do Tata bye bye gya 😂
https://youtu.be/352o8B9IikI?si=OSrhBU0mcFEkqILA
YouTube
How to create compiler bot and run c/c++ java python node js ts from mobile as server in termux
How to create compiler bot and run c/c++ java python node js ts from mobile as server in termux
Create own compiler bot in 2 minutes
Overview:
In this video, I exaplained You about how to use clone Compiler bot to create your own compiler bot.
keys:…
Create own compiler bot in 2 minutes
Overview:
In this video, I exaplained You about how to use clone Compiler bot to create your own compiler bot.
keys:…
👍1
If you want learn js for website development 👇join it
@react_next_js
For any problems in js site development feel free to ask questions 😊👇
@reactjs_nextjs_group
@react_next_js
For any problems in js site development feel free to ask questions 😊👇
@reactjs_nextjs_group
━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Free Study Resources everything join more ✅ https://t.me/addlist/c3QWwWR-Iw4xMDNl
Subscribe Our New channel for coding, designing, hacking and computer related everything 😁
👉✅ https://youtube.com/@CODEBOMBB
━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Free Study Resources everything join more ✅ https://t.me/addlist/c3QWwWR-Iw4xMDNl
Subscribe Our New channel for coding, designing, hacking and computer related everything 😁
👉✅ https://youtube.com/@CODEBOMBB
━━━━━━━━━━━━━━━━━━━━━━━━━━━━
👍1
This media is not supported in your browser
VIEW IN TELEGRAM
👩💻 Welcome to @CodesSnippet! 🔫
Join us for daily snippets of coding👩💻 knowledge! 💻
Here, you'll find 👀 bite-sized pieces of code, programming tips, and tricks to level up your coding skills! 💻
Stay updated on the latest trends in the tech world and engage with fellow coders 💗 in our vibrant community! 🌐💬
Let's crack the coding 👩💻 together and bring your projects to life!
⭐️👨💻
Lang : Python , Java, Javascript, c++ and many more.
#CodeSnippet
#ProgrammingFun
Jᴏɪɴ ᴜs :- @CodesSnippet
Join us for daily snippets of coding👩💻 knowledge! 💻
Here, you'll find 👀 bite-sized pieces of code, programming tips, and tricks to level up your coding skills! 💻
Stay updated on the latest trends in the tech world and engage with fellow coders 💗 in our vibrant community! 🌐💬
Let's crack the coding 👩💻 together and bring your projects to life!
⭐️👨💻
Lang : Python , Java, Javascript, c++ and many more.
#CodeSnippet
#ProgrammingFun
Jᴏɪɴ ᴜs :- @CodesSnippet
👍2❤1