Guitar and violin are both stringed instruments . What is the basic difference in playing these two instrumenys
They belong to two different categories of stringed instruments, bowed instruments vs. plucked instruments. The violin can sustain a note for a very long time because of the bow; the guitar has far less sustain and the tone decays rapidly after the initial attack. The guitar also has a percussive quality, and the violin has far less of this, though it can be played pizzicato.
The violin is louder than the (unamplified acoustic) guitar, and its resonating chamber is smaller, obviously. The violin tends to play melodic lines, and it makes a great ensemble instrument or a featured solo instrument within an orchestral context. The guitar, somewhat like piano, can play isolated melodic lines, but it is also an all-in-one instrument, with melody and accompaniment and multiple voices easily combined at the same time. Because of this, again like piano, it makes a good accompaniment instrument, although unless amplified it won’t be as loud as piano and could be overwhelmed by some instruments.