Recent programs

RENZ DANIEL GOLE CRUZ

an anonymous user · August 13, 2020 · C#
using System;

namespace MyCompiler {
    class Program 
    {   
        public static void Main(string[] args)
        {
        
           
            Console.WriteLine("*********************");
            Console.WriteLine("*********************");

RENZ DANIEL GOLE CRUZ

an anonymous user · August 13, 2020 · C#
using System;

namespace MyCompiler {
    class Program 
    {   
        public static void Main(string[] args)
        {
        
           
            Console.WriteLine("*********************");
            Console.WriteLine("*********************");

RENZ DANIEL GOLE CRUZ

an anonymous user · August 13, 2020 · C#
using System;

namespace MyCompiler {
    class Program 
    {   
        public static void Main(string[] args)
        {
        
           
            Console.WriteLine("*********************");
            Console.WriteLine("*********************");

Hello

an anonymous user · August 12, 2020 · Assembly
section .data
    msg db "Hello world!", 0ah

section .text
    global _start

_start:
    mov rax, 1
    mov rdi, 1
    mov rsi, msg
    mov rdx, 13

Hello

an anonymous user · August 12, 2020 · SQL
-- create a table
CREATE TABLE students (
  id INTEGER PRIMARY KEY,
  name TEXT NOT NULL,
  gender TEXT NOT NULL
);
-- insert some values
INSERT INTO students VALUES (1, 'Ryan', 'M');
INSERT INTO students VALUES (2, 'Joanna', 'F');
-- fetch some values
SELECT * FROM students WHERE gender = 'F';

Hello

an anonymous user · August 12, 2020 · Assembly
section .data
    msg db "Hello world!", 0ah

section .text
    global _start

_start:
    mov rax, 1
    mov rdi, 1
    mov rsi, msg
    mov rdx, 13

Hello

an anonymous user · August 12, 2020 · Assembly
section .data
    msg db "Hello world!", 0ah

section .text
    global _start

_start:
    mov rax, 1
    mov rdi, 1
    mov rsi, msg
    mov rdx, 13

rtr

an anonymous user · August 12, 2020 · C
#include <stdio.h>

int main() {
    printf("Hello world!\n");
    return 0;
}

ejemplo php

an anonymous user · August 12, 2020 · PHP
  <?php
  $dia = date("d");
  if ($dia <= 10) {
    echo "sitio activo";
  } else {
    echo "sitio fuera de servicio";
  }
  ?>

ejemplo php

an anonymous user · August 12, 2020 · PHP
  <?php
  $dia = date("d");
  if ($dia <= 10) {
    echo "sitio activo";
  } else {
    echo "sitio fuera de servicio";
  }
  ?>

SimpleNetworkVicsek test Common

an anonymous user · August 12, 2020 · Fortran
    program VicsekTEST
! 6000 nodes is OK for 1 step but 2 is too much
!7000 nodes takes too much time!
!10000 nodes is inapropriate
!4000 is IK for 4 links per node
integer Nodes, Mlinks
integer i,k,l,m,n,nstep,maxCon
integer AT(7000,7000),Con(7000)
    real V(7000,2)
    common AT,Con,V
        real noise, ampl, Fmetric,TFmetric   ! Fmetric

Creating tables

an anonymous user · August 12, 2020 · SQL
-- create a table
CREATE TABLE students (
  id INTEGER PRIMARY KEY,
  name TEXT NOT NULL,
  gender TEXT NOT NULL
);
-- insert some values
INSERT INTO students VALUES (1, 'Ryan', 'M');
INSERT INTO students VALUES (2, 'Joanna', 'F');
-- fetch some values
SELECT * FROM students WHERE gender = 'F';

tabla 1

an anonymous user · August 12, 2020 · SQL
create table t1 (codigo_t1 primary key,
nombre varchar(30),
edad varchar(30),
sueldo varchar(30),
genero varchar(30));
insert  into t1
(nombre,edad,sueldo,genero)
values ("Jose","30","5000","masculino"),
("Sergio","23","8000","masculino"),
("Raul","34","2000","masculino"),
("Nicol","22","5000","femenino"),

IIFE

italow · August 12, 2020 · NodeJS
//IIFE = imeadiatelly invoked function expression

(function() {
    console.log('Será executado na hora')
    console.log('Foge do escopo mais abrangente')
})()

Devil hacker

an anonymous user · August 12, 2020 · Lua
print 'hello world!'

-- main code
gg.searchNumber("16352", gg.TYPE_DWORD, false, gg.SIGN_EQUAL, 0, -1, 0)

revert = gg.getResults(100, nil, nil, nil, nil, nil, nil, nil, nil)
local t = gg.getResults(100, nil, nil, nil, nil, nil, nil, nil, nil)
for i, v in ipairs(t) do
	if v.flags == gg.TYPE_DWORD then
		v.value = "0"
		v.freeze = true

desafio função construtora

italow · August 12, 2020 · NodeJS
function Pessoa(nome) {
    this.nome = nome
    
    this.falar = function() {
        console.log(`Meu nome é ${this.nome}`)
    }
}

const p1 = new Pessoa('João')
p1.falar()

LeapYear.java

ccpplinux · updated August 12, 2020 · Java
//Program to check whether a year is leap or not using nested if-else statement
/*
    A century year is leap year when it is fully divided by 400 otherwise non leap year
    A non century year is leap year when it is fully divided by 4 otherwise non leap year
*/
import java.util.Scanner;
class Main
{
    public static void main(String args[])
    {
        //Variable

class vs factory

italow · August 12, 2020 · NodeJS
class Pessoa {
    constructor(nome) {
        this.nome = nome
    }
    
    falar() {
        console.log(`Meu nome é ${this.nome}`)
    }
}

//factory

pbm36

an anonymous user · August 12, 2020 · Fortran
program main
    print *, "Hello world!"
end program main

Method overloading

an anonymous user · August 12, 2020 · Java
package session7;
public class MathClass {
    
    /**
     * Method to add two integers
     * 
     * @param num1 an integer variable storing the value of first Number
     * @param num2 an integer variable storing the value of second Number
     * @return  void
     */
     public void add(int num1, int num2) {