Forgot your password?
typodupeerror

Comment Re:No it won't (Score 1) 110

Actually I've found ChatGPT can generate entire running programs that compile out of the box. The trick is not to try it in one prompt. Instead describe what you sort of want to give it context. Then list the functionality, etc. The trick is to "convince" it, to give you the code in one block:

My final prompt was: "now create the code c#, use compact code, most of it in one line don't use line breaks. dont comment"

Gives you a nice nearly unreadable block of code, that is in my case an a working RPG Text game in a c# console application. I don't see what is logically in the way of scaling this approach once the technology allows for longer output text. And if one doesn't like what one gets, one can always complain and it will try to make it better.

1. Define monsters 2. Let monsters apear random to the player 3. Fight choices: Fight, Run, Defend 4. Have a player life and all in a game loop

using System;using System.Linq;class RPG{enum MonsterType{Goblin,Orc,Dragon}MonsterType[] monsters = {MonsterType.Goblin,MonsterType.Orc,MonsterType.Dragon};Random rand = new Random();int playerHealth = 100;bool isAlive = true;string charClass=Enum.GetNames(typeof(Classes))[new Random().Next(Enum.GetNames(typeof(Classes)).Length)], charName, charGender=Enum.GetNames(typeof(Gender))[new Random().Next(Enum.GetNames(typeof(Gender)).Length)];int[] charStats=Enumerable.Range(1,Enum.GetNames(typeof(Stats)).Length).Select(i=>new Random().Next(1,20)).ToArray();Location charLocation=Enum.GetValues(typeof(Location)).Cast().ToArray()[new Random().Next(Enum.GetValues(typeof(Location)).Length)];string[] charEquipment=Enumerable.Range(1,5).Select(i=>Enum.GetNames(typeof(Equipment))[new Random().Next(Enum.GetNames(typeof(Equipment)).Length)]).ToArray();string[] charInventory=Enumerable.Range(1,5).Select(i=>Enum.GetNames(typeof(Items))[new Random().Next(Enum.GetNames(typeof(Items)).Length)]).ToArray();void StartGame(){Console.WriteLine($"Character Class: {charClass}\nCharacter Name: {(string.IsNullOrEmpty(charName)? "": charName)}\nCharacter Gender: {charGender}\nCharacter Stats: {string.Join(",",charStats)}\nCharacter Location: {charLocation}\nCharacter Equipment: {string.Join(",",charEquipment)}\nCharacter Inventory: {string.Join(",",charInventory)}\nPress any key to start the game");Console.ReadLine();while(isAlive){MonsterType nextMonster = monsters[rand.Next(monsters.Length)];Console.WriteLine("A wild " + nextMonster + " appears! What will you do? (Fight, Run, Defend)");string playerChoice = Console.ReadLine();switch(playerChoice){case "Fight":int damageDealt = rand.Next(20);int monsterDamage = rand.Next(10);playerHealth -= monsterDamage;Console.WriteLine("You deal " + damageDealt + " damage to the monster and take " + monsterDamage + " damage yourself. Your remaining health is: " + playerHealth);break;case "Run":Console.WriteLine("You run away.");break;case "Defend":int damageBlocked = rand.Next(5);Console.WriteLine("You block " + damageBlocked + " damage.");break;default:Console.WriteLine("Invalid choice. Please choose 'Fight', 'Run', or 'Defend'.");break;}}}}enum Classes{Warrior,Mage,Rogue}; enum Gender{Male,Female}; enum Stats{Strength,Dexterity,Intelligence}; enum Location{Palace,Forest,Mountain}; enum Equipment{Sword,Shield,Bow,Staff,Dagger}; enum Items{HealthPotion,ManaPotion,Gold,Book,Food};}

Comment Problem is if AI raises standards (Score 1) 69

The issue is that if AI gets better and is utilized to write essays by students, it will also put non-cheating students at a disadvantage. Ultimately, this could result in a failure of the system, similar to the effects of performance-enhancing doping in sports. In the end you have courses that only cheaters can actually pass.

Slashdot Top Deals

The biggest mistake you can make is to believe that you are working for someone else.

Working...