Please i need a 20-50 line code program for a final
I need a 20-50 line code program that completes some kind of task (car door alarm for example) using one but not limited to infra red sensors, led lights, whiskers, or photoresistors. Just type it out for me

Comments
learn var word
you con man
ir var bit
knowledge=good
cheat=bad
school: for you to learn step forward
for you to help
if ir=good then learn=1
if (work.NOT.yourown) then LOW you
if knowledge=cheat then goto jail
goto school
next
jail:stop:end
import sys import math import numpy from PIL import Image def Decimal2Binary(n): '''convert decimal integer n to binary string bStr''' bStr = '' if n < 0: raise ValueError, "must be a positive integer" if n == 0: return '00000000' bstr = '' for i in range(8): bstr = str(n % 2) + bstr n = n >> 1 return bstr # # Open the image file and get the basic information about it. # try: im = Image.open(sys.argv[1]) except: # Eventually this should give more useful information (e.g. file does not # exist, or not an image file, or ... print "Unable to open %s" % sys.argv[1] exit(-1) print "format: %s mode: %s palette: %s" % (im.format,im.mode,im.palette) width,height = im.size print "The image is %d x %d" % im.size rgbimg = im.convert('RGB') pixels = list(im.getdata()) #for y in range(height): # for x in range(width): # #print "RGB: %d, %d, %d" %(im.getpixel((x,y))) # #print im.getpixel((x,y)) # #for color in im.getpixel((x,y)): # print "%d, %d: " % (x, y), rgbimg.getpixel((x,y)) # #print "Parsing specific pixel 43, 2: ", rgbimg.getpixel((43, 2)) try: coe = open(sys.argv[2], 'w') except: print "Unable to open %s" % sys.argv[2] exit(-1) coe.write( "memory_initialization_radix = 2;\n") coe.write( "memory_initialization_vector = \n") for y in range(height): for x in range(width): red, green, blue = rgbimg.getpixel((x, y)) red = red & 0b11100000 green = green & 0b11100000 blue = blue & 0b11100000 output = red | (green >> 3) | (blue >> 6) coe.write( Decimal2Binary(output)) coe.write("\n") coe.close() #print hex(output).data prompt_e: .asciiz "\n Please enter the exponent: " prompt_m: .asciiz "\n Please enter the mantissa: " prompt_s: .asciiz "\n Please enter the sign bit: " output: .asciiz "\n Final Result Value: " .text main: #clear registers and $t0, $0, $0 and $t1, $0, $0 and $t2, $0, $0 and $t3, $0, $0 and $t4, $0, $0 and $t5, $0, $0 and $t6, $0, $0 and $t7, $0, $0 li $v0, 4 #prepare to syscall print la $a0, prompt_e syscall li $v0, 5 #prepare to read int syscall #get exponent move $t1, $v0 li $v0, 4 #prepare to syscall print la $a0, prompt_m syscall li $v0, 5 #prepare to read int syscall #get mantissa move $t2, $v0 #Register allocation: # $t1 - exponent # $t2 - mantissa # $t3 - fp number # $t4 - mask # $t5 - counted shifts # $t6 - working register #set up mask ori $t4, $0, 1 sll $t4, $t4, 31 loop: and $t6, $t2, $t4 #test for upper bit bne $t6, $0, cont #if we have shifted so that the upper bit is a 1 then branch sll $t2, $t2, 1 addi $t5, $t5, 1 j loop cont: sll $t2, $t2, 1 #shift out the first one, then shift to mantissa position srl $t3, $t2, 9 addi $t6, $0, 31 sub $t6, $t6, $t1 # subtract 31 - exponent sub $t6, $t6, $t5 # - shift amount addi $t6, $t6, 127 sll $t6, $t6, 23 or $t3, $t3, $t6 nor $t4, $t4, $0 #invert mask and $t3, $t3, $t4 #clear the upper bit print: li $v0, 4 la $a0, output syscall li $v0, 1 move $a0, $t3 syscall j main@engconceptsgeek: Pay no attention to these naysayers. I'll do it for free and send it straight to your prof to save you the trouble. What's his name and email address?
That will free you up to find people to do your other finals for you.
library IEEE; use IEEE.STD_LOGIC_1164.ALL; use IEEE.NUMERIC_STD.ALL; -- Uncomment the following library declaration if instantiating -- any Xilinx primitives in this code. --library UNISIM; --use UNISIM.VComponents.all; entity scounter32 is Port ( clock : in STD_LOGIC; reset : in STD_LOGIC; enable : in STD_LOGIC; count : out STD_LOGIC_VECTOR (31 downto 0); overflow : out STD_LOGIC); end scounter32; architecture Structural of scounter32 is signal internal_count, increment_size : STD_LOGIC_VECTOR(31 downto 0); begin --initialization increment_size <= X"00000001"; --main process main : process(clock, reset, enable) is begin if clock'event and clock='1' then if reset='1' then internal_count <= X"00000000"; elsif enable='1' then internal_count <= STD_LOGIC_VECTOR(unsigned(internal_count) + unsigned(increment_size)); end if; end if; end process main; count <= internal_count; --set overflow overflow <= '1' when internal_count = X"00000000" and enable='1' else '0'; end Structural;pulsout 13 program that incorporates whiskers or photoresistors?
It always helps to insult those from whom you are asking a favor.
We don't help you because we do not, as a forum, condone cheating. Asking for someone else to do your final for you is cheating, and all of us here on the forum have gotten to where we are now by hard work and dedicated effort. It grates on our nerves to see somebody insult us, command us to do something, and not even use decent English.
I hope that failure will teach you something.
You are asking us to do something for the sake of helping you that causes us a moral conflict as a group. We won't. If you are mature enough for an AP program, then you should be mature enough to grow through adversity and failure.
Best of luck in your six other finals!
Spend half an hour with the manuals on your board, and you'll have no problem at all writing your program. And, it may just surprise you how much you actually enjoy the process.
You are too funny! Your examples are great. I wonder if this guy actually tried to compile any of the the code you posted [laughing].
The sad thing is that this guy probably did find someone to do his work for him. There are so many cheaters in the world - it makes me sick.
Great work!
Paul
Hey! I've compiled (or synthesized or assembled or ran through the interpreter as appropriate) each of those programs. They work, 100% guaranteed!
The greatest reward of cheating is ignorance, and ignorance is bliss. This guy is simply seeking happiness
To charge a battery very quickly, you simply connect the negative terminal to the positive terminal. It won't take long, trust me
Bruce
The best part is that the company doesn't care, the cheaters are a statistical variance that they can tolerate.
It's like voting, the same "security", none, to keep it all "accessible".
I saw your program and thought it was great. I made some modiciations - you might want to make sure it compiles before we send it to engconceptsgeek. I think this may help out engconceptsgeek with his problem - ok, I felt sorry for him.
' {$STAMP BS2}
' {$PBASIC 2.5}
' { PORT COM1}
DATA @0, "Program: ", "<TILE OF YOUR PROGRAM HERE>", 0
DATA " Date: ", "<ENTER DATE HERE>", 0
DATA " By: ", "<YOUR NAME HERE>", 0
DATA "!jt!b!MPTFS/" ' Initialization string
GOOD CON 1
BAD CON 0
OK CON GOOD
man CON GOOD
learn CON GOOD
cheat CON BAD
you VAR Bit
ask VAR Bit
yourown VAR Bit
help VAR Nib
forward VAR Byte
work VAR Word
knowledge VAR Word
forward = GOOD
knowledge = GOOD
help = OK
yourown = GOOD
work = 0
school: FOR you = man TO learn STEP forward
FOR you = ask TO help STEP GOOD
IF work = yourown THEN you = learn
IF NOT yourown = work THEN you = cheat
IF you = cheat THEN GOTO jail
GOTO school
NEXT
NEXT
jail: GOSUB jail1 : STOP : END
jail1:
work = 0
help = 0
booked1:
READ work, forward
work = work + 1
IF forward = 0 THEN GOTO booked2
DEBUG forward
GOTO booked1
booked2:
DEBUG CR
help = help + 1
IF (help = 2) THEN
DEBUG CR, CR, " "
GOTO committed
ENDIF
GOTO booked1
committed:
work = work + 9
FOR work = work TO 65535
READ work, forward
IF forward = 60 THEN
DEBUG "Author's name was not entered in source code <YOUR NAME HERE> Example: DATA ", 34, " By: ", 34, ", ", 34, "John Smith", 34
GOTO booked4
ENDIF
IF forward = 0 THEN GOTO booked3
DEBUG forward
NEXT
booked3:
work = work + 1
FOR work = work TO 65535
READ work, forward
IF forward = 47 THEN GOTO booked4
DEBUG (forward - 1)
NEXT
booked4:
RETURN
'
' End of Program.
'
Gee, I thought that was how to DIScharge a battery quickly. Or start a fire quickly, especially if you use 0000 steel wool. (Yes, it works. Wanna see my scorched fingertips?
--Rich