Skip to content

Instantly share code, notes, and snippets.

View Fyronix's full-sized avatar
💻
Working from home

Fyronix Fyronix

💻
Working from home
View GitHub Profile
@Fyronix
Fyronix / main.java
Created January 12, 2022 21:58
A simple rock paper scissors in java
import java.util.Random;
import java.util.Scanner;
public class RockPaperScissors {
public static void main(String[] args) {
//Setting Up
String[] options = new String[]{"Rock", "Paper", "Scissors"};
Scanner scanner = new Scanner(System.in);
Random random = new Random();
@Fyronix
Fyronix / cosinus.cpp
Created January 12, 2022 19:56
A simple calculator in cpp for have cosinus in trigonometri.
// Cos code
#include <iostream>
#include <cmath>
using namespace std;
int main()
{
int x = 1;
double result;
@Fyronix
Fyronix / sinus.cpp
Created January 12, 2022 19:53
A simple calculator in cpp for have sinus in trigonometrie.
// Sin code
#include <iostream>
#include <cmath>
using namespace std;
int main()
{
int x = -1;
double result;
@Fyronix
Fyronix / tangente.cpp
Created January 12, 2022 19:52
A simple calculator in cpp for have tangente in trigonometrie
// Tan code
#include <iostream>
#include <cmath>
using namespace std;
int main()
{
int x = 25;
double result;
class Main {
public static void main(String args[]) {
System.out.println("Hello, world!");
}
}
@Fyronix
Fyronix / server.cpp
Created December 17, 2021 09:12
Client and server
int main(){
/** MC socket **/
struct sockaddr_in groupSock;
groupSock.sin_family = AF_INET;
groupSock.sin_addr.s_addr = inet_addr("225.5.4.30");
groupSock.sin_port = htons(54321);
bzero(&(groupSock.sin_zero),8);
@Fyronix
Fyronix / getlocalisation.html
Created December 7, 2021 22:17
Get your localisation html
<!DOCTYPE html>
<html>
<body>
<p>Click the button to get your coordinates.</p>
<button onclick="getLocation()">Try It</button>
<p id="demo"></p>
@Fyronix
Fyronix / hello-world.asm
Last active December 4, 2021 23:35
Hello world in assembly
section .text
global _start ;must be declared for using gcc
_start: ;tell linker entry point
mov edx, len ;message length
mov ecx, msg ;message to write
mov ebx, 1 ;file descriptor (stdout)
mov eax, 4 ;system call number (sys_write)
int 0x80 ;call kernel
mov eax, 1 ;system call number (sys_exit)
int 0x80 ;call kernel
@Fyronix
Fyronix / gitlab.svg
Created December 4, 2021 09:26
Gitlab svg card
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@Fyronix
Fyronix / rock-paper-scissor.py
Created December 1, 2021 20:01
Rock paper Scissor using python
from random import randint
#create a list of play options
t = ["Rock", "Paper", "Scissors"]
#assign a random play to the computer
computer = t[randint(0,2)]
#set player to False
player = False