Joint Learning of Network Topology and Opinion Dynamics Based on Bandit Algorithms