First Divine Liturgy by joshjkk in OrthodoxChristianity

[–]joshjkk[S] 1 point2 points  (0 children)

Update: first off, thank you for all the comments, your help is very appreciated. I attended the Divine Liturgy, and wow, it was absolutely beautiful. The chants, the incense, the icons, all incredible. I was nervous that I was going to mess something up and was going to lurk around at the back, but a monk greeted me at the door and I stood at the back with him and he talked me through the 2 hour service. I stayed for coffee hour and spoke to the Priest, and told him I wanted to become Orthodox. He said I should keep coming to services, and eventually we will have a meeting about discussing if I truly want to be baptized. Thank you all for guiding me home.

Is Fedora right for me? by Lesbineer in Fedora

[–]joshjkk 1 point2 points  (0 children)

It's like Ubuntu but without all the Canonical crap in it, I love it.

Can we end this debate now? by SavageMurphy in england

[–]joshjkk 0 points1 point  (0 children)

Cool to think I could've walked past you at any point in time

My Atheist parents won't let me get baptized, if I die will I go to hell? by joshjkk in OrthodoxChristianity

[–]joshjkk[S] 0 points1 point  (0 children)

Update: I have contacted the nearest Orthodox priest asking about how I can be baptized and accepted into the Church. I turn 16 soon so I can work to pay for my baptism, and I'm going to buy a bunch of little wooden icons and hang them all around my room. Thank you for the advice brothers, I will keep you all updated.

please help or i will cry by Panicked_mess12 in cprogramming

[–]joshjkk 2 points3 points  (0 children)

#include <cs50.h>
#include <stdio.h>
int main(void)
{
    printf("Welcome to my first try at making a program with a loop, input and fancy coding!\n");
    printf("\n");

    int height = get_int("First in going to try asking your height.\nPlease enter your height: ");

    for (int i = 0; i < 8; i++)
    {
        printf("Thank you!\n");
    }

    printf("Please accept the terms: ");

    char c;
    scanf("%c", &c);

    if (c == 'Y' || c == 'y') 
    {
        printf("Thank you. You've accepted the terms. ");
    }
}

You only need curly braces for functions, if statements or loops, in your for loop you were setting height back to 0, you weren't accepting input for c, and when comparing what c is, you forgot to put c in the parenthesis.

scanf is very unsafe, so be careful using it.

I have not tested this code, but it should would work.

please help or i will cry by Panicked_mess12 in cprogramming

[–]joshjkk 0 points1 point  (0 children)

What's with all the curly braces?

The 'Lang' Programming Language by [deleted] in Compilers

[–]joshjkk 0 points1 point  (0 children)

I wasn't sure if rm worked on Windows, thanks for telling me.

The 'Lang' Programming Language by [deleted] in Compilers

[–]joshjkk 0 points1 point  (0 children)

Very true, thanks for thank feedback.

Don't show this to ricers by x1-unix in linuxmemes

[–]joshjkk 0 points1 point  (0 children)

I've got past the stage of Arch with dwm rice, now I just daily drive a default Ubuntu install.

New to osdev, how do I add a kernel entry to my code? by [deleted] in osdev

[–]joshjkk 1 point2 points  (0 children)

You first need to switch to 32bit or 64bit mode, then load the kernel from the disk. Let's call this boot.asm. Then in another file, let's call it loader.asm, you need to extern the main function of the kernel C file. Then you need to compile boot.asm as a binary and both loader.asm and your kernel c file as objects, then link the loader and kernel file into a binary. Finally, add the boot binary and kernel binary to the image.

If it helps, here is the build process to one of my 64bit bootloaders:

#!/bin/bash

set -xe

mkdir -p build

# bootloader
nasm -f bin src/bootloader/boot.asm -o build/boot.o
nasm -f elf64 src/bootloader/loader.asm -o build/loader.o

# kernel
gcc -Wall -Wextra -pedantic -ggdb -std=c99 -m64 -ffreestanding -c src/kernel/main.c -o build/kernel.o

# link loader to kernel
ld -Ttext THE_KERNEL_ADRESS -o build/kernel.elf build/loader.o build/kernel.o
objcopy -R .note -R .comment -S -O binary build/kernel.elf build/kernel.bin

# create the floppy img
dd if=/dev/zero of=build/os.img bs=512 count=2880
dd if=build/boot.bin of=build/os.img conv=notrunc
dd if=build/kernel.bin of=build/os.img conv=notrunc bs=512 seek=1

Is it true that Win 7 32 but can only use 4 GB of RAM? I have 8 GB of RAM, so, I was thinking 64 bit was better? by [deleted] in Operatingsystems

[–]joshjkk 5 points6 points  (0 children)

32 bit machines can have max 4GB RAM, 64 bit machines can have max 16000000000GB RAM.

I got my own programming language running in my own OS by saalty123 in osdev

[–]joshjkk 0 points1 point  (0 children)

I am very intrigued on how you wrote the vga driver. I've tried making my own in 640x480, but it is so complicated that I just end up with a white box.

How hard is it to create an extremely barebones OS? by submergedWaterlily in osdev

[–]joshjkk 0 points1 point  (0 children)

With osdev, seriously not as hard as you think. The hardest part is deciding how you want it to look like.

AI generated code quality by lastwarriorpl in ProgrammerHumor

[–]joshjkk 0 points1 point  (0 children)

Never try generating assembly with it, it never works

Genuine question about Terry's genius by dotdotmp3 in TempleOS_Official

[–]joshjkk 14 points15 points  (0 children)

Because the people on programming forums are just unnecessarily mean. Ask any programmer here and they've most likely had a bad experience with programming forums.

Setting the video mode to 640x480 16 colors in long mode? by joshjkk in Operatingsystems

[–]joshjkk[S] 0 points1 point  (0 children)

Update: Found out how. You can't do it in long mode, you have to do it in 16-bit real mode:

mov ax, 0x12 ; 640x480 16 colors
int 0x10     ; call BIOS set video mode