var answerBar=document.getElementById("answerSelect");
var start_left;
var end_left;
answerBar.addEventListener("touchstart",function(event){
event.preventDefault();
if (event.targetTouches.length == 1) {
var touch = event.targetTouches[0];
start_left = touch.pageX;
}
},false);
answerBar.addEventListener("touchmove",function(event){
event.preventDefault();
if (event.targetTouches.length == 1) {
var touch = event.targetTouches[0];
end_left = touch.pageX;
}
},false);
answerBar.addEventListener("touchend",function(event){
if(end_left-start_left>40){
console.info("r");
}
else if(start_left-end_left>40){
console.info("l");
}
},false);