I have a project I am doing for a class in which I am given 3 7 segment common anode LED, a rotary encoder, and an Arduino Uno, along with 3 resistor banks to connect from the led to the arduino which I have done so in parallel resistors to the Arduino. I am to display the angle of the rotary encoder on the 3 LEDs. I have the anode pins connected to 4 5 and 6. while my encoder pin a is connected to pin 2 , and pin b is connected to 3. The parallel resistor connections from the LED's are connected to 7 - 13. I am trying to type a code for this circuit but I have no previous experience on how to code for arduino. Any guidance would be helpful on this project.
Also look up multiplexing. Each of the three 7 segment LEDs is switched on in turn for a fraction of a second so as to appear that all three are simultaneously lit. With the Arduino pins you have available, you are forced to use this solution.