First of all: Welcome to the forums! We hope to see some really neat code from you in the future.
Second, that's not exactly how code works. You are trying to use shell.run cor everything, which CAN work, eventually, but it is far from ideal. In your example:
shell.run(red,lbrt,2,.5)
I assume you want all of the sides to flash twice, with half second intervals, right? I am going to continue assuming you are.
What you want for this whole thing, is to use your own program code, instead of shells. Shells just add more and more programs. We don't want that. We want to call functions, variables, and tables. We can learn about the more complicated things later.
Say for example, you want to flash out of the right side, five times, with half second intervals. We are wanting this code to go with it:
for i = 1,5 do --this will start a loop, and will run five times
--1 is the starting point, 5 is the end point
rs.setOutput("right",true) --this will set the output on the right side ON
sleep(.5) --this will stop for half a second
rs.setOutput("right",false) --this will turn off the signal on the right
sleep(.5) --again, waiting half a second
end --ending the loop we created
I have added comments, (which start with a – in lua, always) that should explain what each part of the code does.
You're new here, so you should use the wiki a bit to get your footing, and check out the useful tips and resources thread that is stickied at the top of the Ask a Pro section. There are some great tools to help you learn how to use ComputerCraft.
Again, welcome to the forums, and Happy Hacking!