How To Code A Unit Converter In C# | Programming Tutorial For Beginners

preview_player
Показать описание
Thanks for watching! :)

This project is available on GitHub at
--------------------------------------------------------------------------------------

Add Me On Discord!
--------------------------------------------------------------------------------------
Username: Shaun(Hashtag)5626

Want to see more?
--------------------------------------------------------------------------------------

Legal Disclaimer
--------------------------------------------------------------------------------------
Assets in the thumbnail & video were provided by artists on

The art used in this video is from Canva and is used solely for the purpose of enhancing or demonstrating these coding tutorials. I do not claim ownership or credit for any of the art shown in this video. I am a paid member of Canva Pro and have the rights to use the art in this video as outlined in my membership agreement. If you have any questions about the use of the art in this video, please contact me.

Video Tags
--------------------------------------------------------------------------------------
Software Engineering / Programming for beginners / variables types / computer science / compsci / coding for beginners / learn how to program / learn how to code / C# variables / python for beginners / coding tutorial / programming tutorial

#programming #tutorial #learntocode
Рекомендации по теме
Комментарии
Автор

3:04 The "string" type in C# has a lowercase "S", not an uppercase like in Java. Visual Studio is trying to tell you that there is a problem with your code because it underlined the "Console.ReadLine" and the "input" variable on the same line. Same for args in the Main declaration
Also would put the welcome outside of the loop because you only need to welcome the user the first time, not every time the loop is ran.

rhtservicestech
Автор

Bro thanks, for tutorials like these it helped me so much ❤❤

shayanalam
Автор

Hello dear, i have watched your video about ping pong on c#, and found a bug, i dont know how to fix it, maybe you have any idea 😦
Bug associated with the fact that when you bounce the ball from the pedal, it can bounce only from the side, maybe you know how to make the ball bounce from both the top end

tranquil
Автор

Nice, can you code this, I put it in chatgpt but I don't know how to actually make it work😅
import pygame
import random

# Initialize Pygame
pygame.init()

# Set up the screen
width = 800
height = 600
screen = pygame.display.set_mode((width, height))
Rescue Game")

# Colors
BLACK = (0, 0, 0)
WHITE = (255, 255, 255)
RED = (255, 0, 0)

# Player variables
player_width = 50
player_height = 50
player_x = width // 2 - player_width // 2
player_y = height - player_height - 10
player_speed = 5

# Pizza variables
pizza_width = 100
pizza_height = 100
pizza_x = random.randint(0, width - pizza_width)
pizza_y = 0
pizza_speed = 3

# People variables
people_width = 30
people_height = 30
people_x = random.randint(0, width - people_width)
people_y = random.randint(0, height - people_height)

# Game loop
running = True
while running:
for event in pygame.event.get():
if event.type == pygame.QUIT:
running = False

# Move the player
keys = pygame.key.get_pressed()
if keys[pygame.K_LEFT] and player_x > 0:
player_x -= player_speed
if keys[pygame.K_RIGHT] and player_x < width - player_width:
player_x += player_speed

# Move the pizza down
pizza_y += pizza_speed

# Collision detection
if player_x < pizza_x + pizza_width and player_x + player_width > pizza_x and player_y < pizza_y + pizza_height and player_y + player_height > pizza_y:
# Player collided with pizza
pizza_y = 0
pizza_x = random.randint(0, width - pizza_width)
people_x = random.randint(0, width - people_width)
people_y = random.randint(0, height - people_height)

# Clear the screen
screen.fill(BLACK)

# Draw the player
pygame.draw.rect(screen, RED, (player_x, player_y, player_width, player_height))

# Draw the pizza
pygame.draw.rect(screen, WHITE, (pizza_x, pizza_y, pizza_width, pizza_height))

# Draw the person to rescue
pygame.draw.rect(screen, WHITE, (people_x, people_y, people_width, people_height))

# Update the screen
pygame.display.flip()

# Quit the game
pygame.quit()

slightofhand